Documentation
¶
Index ¶
- Constants
- Variables
- func Args() []string
- func Dispatch(a Application) error
- func Register(commands ...Command)
- func ReportMigrationState(app Application)
- func Requested() string
- func RequireServer(addr string) error
- func ServerRunning(addr string) bool
- type Application
- type CheckMessages
- type CollectStatic
- type Command
- type Context
- type CreateSuperadmin
- type DBShell
- type JobWorker
- type MakeMessages
- type MakeMigrations
- type Migrate
- type PermissionSyncer
- type Registry
- type Report
- type Rollback
- type SQLMigrate
- type Shell
- type Start
- type SyncPermissions
- type Worker
Constants ¶
View Source
const ( EnvCommand = "COYOTE_COMMAND" EnvPort = "COYOTE_PORT" EnvHost = "COYOTE_HOST" EnvName = "COYOTE_MIGRATION_NAME" EnvUsername = "COYOTE_SUPERADMIN_USERNAME" EnvEmail = "COYOTE_SUPERADMIN_EMAIL" EnvPassword = "COYOTE_SUPERADMIN_PASSWORD" EnvFake = "COYOTE_MIGRATE_FAKE" EnvTarget = "COYOTE_MIGRATE_TARGET" EnvSteps = "COYOTE_MIGRATE_STEPS" EnvNoInput = "COYOTE_NO_INPUT" EnvForce = "COYOTE_FORCE" EnvArgs = "COYOTE_ARGS" EnvLocale = "COYOTE_LOCALE" EnvStrict = "COYOTE_STRICT" EnvUndo = "COYOTE_MIGRATION_UNDO" EnvWorkers = "COYOTE_JOB_WORKERS" EnvQueues = "COYOTE_JOB_QUEUES" )
View Source
const ( NameStart = "start" NameMigrate = "migrate" NameSyncPermissions = "syncpermissions" NameCollectStatic = "collectstatic" NameWorker = "worker" )
View Source
const NameCheckMessages = "checkmessages"
View Source
const NameCreateSuperadmin = "createsuperadmin"
View Source
const NameDBShell = "dbshell"
View Source
const NameMakeMessages = "makemessages"
View Source
const NameMakeMigrations = "makemigrations"
View Source
const NameRollback = "rollback"
View Source
const NameSQLMigrate = "sqlmigrate"
View Source
const NameShell = "shell"
Variables ¶
View Source
var ErrIncompleteCatalog = errors.New("coyote/cli: translations are incomplete")
View Source
var ErrSchemaMissing = errors.New("coyote/cli: the users table does not exist yet")
View Source
var ErrServerNotRunning = errors.New("coyote/cli: server is not running")
View Source
var ErrUnknownCommand = errors.New("coyote/cli: unknown command")
Functions ¶
func Dispatch ¶
func Dispatch(a Application) error
func ReportMigrationState ¶
func ReportMigrationState(app Application)
func RequireServer ¶
func ServerRunning ¶
Types ¶
type Application ¶
type CheckMessages ¶
func CheckMessagesFromEnv ¶
func CheckMessagesFromEnv() CheckMessages
func (CheckMessages) Name ¶
func (CheckMessages) Name() string
func (CheckMessages) Run ¶
func (c CheckMessages) Run(ctx Context) error
func (CheckMessages) Summary ¶
func (CheckMessages) Summary() string
type CollectStatic ¶
type CollectStatic struct{}
func (CollectStatic) Name ¶
func (CollectStatic) Name() string
func (CollectStatic) Run ¶
func (CollectStatic) Run(ctx Context) error
func (CollectStatic) Summary ¶
func (CollectStatic) Summary() string
type Command ¶
func Registered ¶
func Registered() []Command
type Context ¶
type Context struct {
App Application
Out io.Writer
In io.Reader
}
func (Context) Interactive ¶
type CreateSuperadmin ¶
func (CreateSuperadmin) Name ¶
func (CreateSuperadmin) Name() string
func (CreateSuperadmin) Run ¶
func (c CreateSuperadmin) Run(ctx Context) error
func (CreateSuperadmin) Summary ¶
func (CreateSuperadmin) Summary() string
type MakeMessages ¶
type MakeMessages struct {
Locale string
}
func MakeMessagesFromEnv ¶
func MakeMessagesFromEnv() MakeMessages
func (MakeMessages) Name ¶
func (MakeMessages) Name() string
func (MakeMessages) Run ¶
func (m MakeMessages) Run(ctx Context) error
func (MakeMessages) Summary ¶
func (MakeMessages) Summary() string
type MakeMigrations ¶
func MakeMigrationsFromEnv ¶
func MakeMigrationsFromEnv() MakeMigrations
func (MakeMigrations) Name ¶
func (MakeMigrations) Name() string
func (MakeMigrations) Run ¶
func (m MakeMigrations) Run(ctx Context) error
func (MakeMigrations) Summary ¶
func (MakeMigrations) Summary() string
type Migrate ¶
func MigrateFromEnv ¶
func MigrateFromEnv() Migrate
type PermissionSyncer ¶
type PermissionSyncer interface {
SyncPermissions(ctx context.Context) (auth.SyncReport, error)
}
type Registry ¶
type Registry struct {
// contains filtered or unexported fields
}
func NewRegistry ¶
type Rollback ¶
func RollbackFromEnv ¶
func RollbackFromEnv() Rollback
type SQLMigrate ¶
type SQLMigrate struct{}
func (SQLMigrate) Name ¶
func (SQLMigrate) Name() string
func (SQLMigrate) Run ¶
func (SQLMigrate) Run(ctx Context) error
func (SQLMigrate) Summary ¶
func (SQLMigrate) Summary() string
type SyncPermissions ¶
type SyncPermissions struct{}
func (SyncPermissions) Name ¶
func (SyncPermissions) Name() string
func (SyncPermissions) Run ¶
func (SyncPermissions) Run(ctx Context) error
func (SyncPermissions) Summary ¶
func (SyncPermissions) Summary() string
Source Files
¶
Click to show internal directories.
Click to hide internal directories.