Documentation
¶
Overview ¶
Package ggnew scaffolds the project gg new creates: the first version of every package the generated main.go imports, so the project compiles before its first generation.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EnsureFileExists ¶
EnsureFileExists writes every scaffold file missing from the project in the working directory, among them the empty first versions of the files gg gen owns, and returns the paths it created, sorted.
Types ¶
type ProjectFile ¶
ProjectFile is one file a new project starts with: Content goes to Path, relative to the project directory.
func ProjectFiles ¶
func ProjectFiles(projectName string) ([]ProjectFile, error)
ProjectFiles returns the files gg new writes into a new project, in the order it writes them: the scaffold sorted by path, then main.go, .gitignore and config.ini.example. projectName is the module path the project is created under; its last element names the application in the example configuration, as sampleapp does for example.com/sampleapp.