Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GenerateCommand ¶
type GenerateCommand struct { MigrationDirectory string `short:"d" long:"directory" default:"migrations" description:"The directory to which the migration files should be written"` MigrationName string `short:"n" long:"name" description:"The name of the migration"` Type MigrationType `short:"t" long:"type" description:"The file type of the migration"` }
func NewGenerateCommand ¶
func NewGenerateCommand(migrationDir string, migrationName string, migrationType MigrationType) *GenerateCommand
func (*GenerateCommand) Execute ¶
func (c *GenerateCommand) Execute(args []string) error
func (*GenerateCommand) GenerateGoMigration ¶
func (c *GenerateCommand) GenerateGoMigration() error
func (*GenerateCommand) GenerateSQLMigration ¶
func (c *GenerateCommand) GenerateSQLMigration() error
type MigrationCommand ¶
type MigrationCommand struct {
GenerateCommand GenerateCommand `command:"generate"`
}
type MigrationType ¶
type MigrationType string
const ( SQL MigrationType = "sql" Go MigrationType = "go" )
Click to show internal directories.
Click to hide internal directories.