fix name
This commit is contained in:
@@ -11,24 +11,24 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
type (
|
type (
|
||||||
ListCmd struct {
|
ApplyCmd struct {
|
||||||
Service *data.Service
|
Service *data.Service
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
func (*ListCmd) Name() string { return "apply" }
|
func (*ApplyCmd) Name() string { return "apply" }
|
||||||
func (*ListCmd) Synopsis() string { return "apply a backup" }
|
func (*ApplyCmd) Synopsis() string { return "apply a backup" }
|
||||||
func (*ListCmd) Usage() string {
|
func (*ApplyCmd) Usage() string {
|
||||||
return `Usage: cloudsave apply <GAME_ID> [BACKUP_ID]
|
return `Usage: cloudsave apply <GAME_ID> [BACKUP_ID]
|
||||||
|
|
||||||
Apply a backup
|
Apply a backup
|
||||||
`
|
`
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *ListCmd) SetFlags(f *flag.FlagSet) {
|
func (p *ApplyCmd) SetFlags(f *flag.FlagSet) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (p *ListCmd) Execute(_ context.Context, f *flag.FlagSet, _ ...interface{}) subcommands.ExitStatus {
|
func (p *ApplyCmd) Execute(_ context.Context, f *flag.FlagSet, _ ...interface{}) subcommands.ExitStatus {
|
||||||
if f.NArg() < 1 {
|
if f.NArg() < 1 {
|
||||||
fmt.Fprintln(os.Stderr, "error: missing game ID and/or backup uuid")
|
fmt.Fprintln(os.Stderr, "error: missing game ID and/or backup uuid")
|
||||||
return subcommands.ExitUsageError
|
return subcommands.ExitUsageError
|
||||||
|
|||||||
@@ -51,7 +51,7 @@ func main() {
|
|||||||
subcommands.Register(&remove.RemoveCmd{Service: s}, "management")
|
subcommands.Register(&remove.RemoveCmd{Service: s}, "management")
|
||||||
subcommands.Register(&show.ShowCmd{Service: s}, "management")
|
subcommands.Register(&show.ShowCmd{Service: s}, "management")
|
||||||
|
|
||||||
subcommands.Register(&apply.ListCmd{Service: s}, "restore")
|
subcommands.Register(&apply.ApplyCmd{Service: s}, "restore")
|
||||||
|
|
||||||
subcommands.Register(&remote.RemoteCmd{Service: s}, "remote")
|
subcommands.Register(&remote.RemoteCmd{Service: s}, "remote")
|
||||||
subcommands.Register(&sync.SyncCmd{Service: s}, "remote")
|
subcommands.Register(&sync.SyncCmd{Service: s}, "remote")
|
||||||
|
|||||||
Reference in New Issue
Block a user