Skip to content

Commit

Permalink
fix: Accept web-command cli flags if web-command is commited (go-gite…
Browse files Browse the repository at this point in the history
…a#5245)

* Added flags of default cmd CmdWeb to app-wide flags
* If command *is* specified app-wide flags are ignored

Backport of go-gitea#5200
Signed-off-by: Berengar W. Lehr <Berengar.Lehr@kompetenztest.de>
  • Loading branch information
HoffmannP authored and techknowlogick committed Nov 1, 2018
1 parent 3786369 commit 14a074f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion main.go
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ arguments - which can alternatively be run by running the subcommand web.`
cmd.CmdAdmin,
cmd.CmdGenerate,
}
app.Flags = append(app.Flags, []cli.Flag{}...)
app.Flags = append(app.Flags, cmd.CmdWeb.Flags...)
app.Action = cmd.CmdWeb.Action
err := app.Run(os.Args)
if err != nil {
Expand Down

0 comments on commit 14a074f

Please sign in to comment.