feat: Added migration tool
This commit is contained in:
@@ -6,6 +6,14 @@ type ServerCmd struct {
|
||||
Port string `arg:"-p,--port" help:"Port to listen on" default:"8080"`
|
||||
}
|
||||
|
||||
type MigrationCreate struct {
|
||||
Name string `arg:"-n,--name" help:"Name of migration"`
|
||||
}
|
||||
|
||||
type Migration struct {
|
||||
Create *MigrationCreate `arg:"subcommand:create" help:"Create migration"`
|
||||
}
|
||||
|
||||
type ServerDocumentationCmd struct {
|
||||
Port string `arg:"-p,--port" help:"Port to listen on" default:"8081"`
|
||||
Plain bool `arg:"--plain" help:"Enable plain text output" default:"true"`
|
||||
@@ -14,7 +22,8 @@ type ServerDocumentationCmd struct {
|
||||
|
||||
type AppArgs struct {
|
||||
Server *ServerCmd `arg:"subcommand:server" help:"Start the api server"`
|
||||
ServerDocumentation *ServerDocumentationCmd `arg:"subcommand:server-docs" help:"Generate documentation for api server"`
|
||||
ServerDocumentation *ServerDocumentationCmd `arg:"subcommand:server-docs" help:"Generate documentation for api server and start documentation server"`
|
||||
Migration *Migration `arg:"subcommand:migration" help:"Migration utils"`
|
||||
}
|
||||
|
||||
func (AppArgs) Version() string {
|
||||
|
||||
Reference in New Issue
Block a user