diff options
author | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2018-11-04 18:39:14 +0100 |
---|---|---|
committer | Bjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com> | 2018-11-04 18:39:14 +0100 |
commit | 5b1edd281a493bdb27af4dc3c8fae7e10dd54830 (patch) | |
tree | 330d7e81bb4c7a511f1a83d737fbd7316d66c8d6 /commands/commands.go | |
parent | 2bd9d9099db267831731ed2d2200eb09305df9fc (diff) |
commands: Add --minify to hugo server
Diffstat (limited to 'commands/commands.go')
-rw-r--r-- | commands/commands.go | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/commands/commands.go b/commands/commands.go index 8670d4983..751c263e0 100644 --- a/commands/commands.go +++ b/commands/commands.go @@ -175,7 +175,6 @@ Complete documentation is available at http://gohugo.io/.`, cc.cmd.Flags().BoolVarP(&cc.buildWatch, "watch", "w", false, "watch filesystem for changes and recreate as needed") cc.cmd.Flags().Bool("renderToMemory", false, "render to memory (only useful for benchmark testing)") - cc.cmd.Flags().Bool("minify", false, "minify any supported output format (HTML, XML etc.)") // Set bash-completion _ = cc.cmd.PersistentFlags().SetAnnotation("logFile", cobra.BashCompFilenameExt, []string{}) @@ -232,6 +231,8 @@ func (cc *hugoBuilderCommon) handleFlags(cmd *cobra.Command) { cmd.Flags().StringSlice("disableKinds", []string{}, "disable different kind of pages (home, RSS etc.)") + cmd.Flags().Bool("minify", false, "minify any supported output format (HTML, XML etc.)") + // Set bash-completion. // Each flag must first be defined before using the SetAnnotation() call. _ = cmd.Flags().SetAnnotation("source", cobra.BashCompSubdirsInDir, []string{}) |