fortify: move internal commands up
This improves readability. Signed-off-by: Ophestra <cat@gensokyo.uk>
This commit is contained in:
parent
840ceb615a
commit
56539d8db5
8
main.go
8
main.go
@ -78,6 +78,10 @@ func buildCommand(out io.Writer) command.Command {
|
|||||||
Flag(&flagVerbose, "v", command.BoolFlag(false), "Print debug messages to the console").
|
Flag(&flagVerbose, "v", command.BoolFlag(false), "Print debug messages to the console").
|
||||||
Flag(&flagJSON, "json", command.BoolFlag(false), "Serialise output as JSON when applicable")
|
Flag(&flagJSON, "json", command.BoolFlag(false), "Serialise output as JSON when applicable")
|
||||||
|
|
||||||
|
// internal commands
|
||||||
|
c.Command("shim", command.UsageInternal, func([]string) error { shim.Main(); return errSuccess })
|
||||||
|
c.Command("init", command.UsageInternal, func([]string) error { init0.Main(); return errSuccess })
|
||||||
|
|
||||||
c.Command("app", "Launch app defined by the specified config file", func(args []string) error {
|
c.Command("app", "Launch app defined by the specified config file", func(args []string) error {
|
||||||
if len(args) < 1 {
|
if len(args) < 1 {
|
||||||
log.Fatal("app requires at least 1 argument")
|
log.Fatal("app requires at least 1 argument")
|
||||||
@ -278,10 +282,6 @@ func buildCommand(out io.Writer) command.Command {
|
|||||||
return errSuccess
|
return errSuccess
|
||||||
})
|
})
|
||||||
|
|
||||||
// internal commands
|
|
||||||
c.Command("shim", command.UsageInternal, func([]string) error { shim.Main(); return errSuccess })
|
|
||||||
c.Command("init", command.UsageInternal, func([]string) error { init0.Main(); return errSuccess })
|
|
||||||
|
|
||||||
return c
|
return c
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user