Documentation ¶
Overview ¶
Package genmain provides a generator for a skeleton goa application. This generator generates the code for a basic "main" package and is mainly intended as a way to bootstrap new applications. The generator creates a main.go file and one file per resource listed in the API metadata. If a file already exists it skips its creation unless the flag --force is provided on the command line in which case it overrides the content of existing files.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // AppName is the name of the generated application. AppName string // Force is true if pre-existing files should be overwritten during generation. Force bool )
Functions ¶
Types ¶
type Command ¶
type Command struct {
*codegen.BaseCommand
}
Command is the goa application code generator command line data structure. It implements meta.Command.
func (*Command) RegisterFlags ¶
func (c *Command) RegisterFlags(r codegen.FlagRegistry)
RegisterFlags registers the command line flags with the given registry.
type Generator ¶
type Generator struct {
// contains filtered or unexported fields
}
Generator is the application code generator.
func NewGenerator ¶
NewGenerator returns the application code generator.