Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/gohugoio/hugo.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert van Gent <rvangent@google.com>2018-12-20 22:22:03 +0300
committerBjørn Erik Pedersen <bjorn.erik.pedersen@gmail.com>2019-05-03 18:58:40 +0300
commitc7165589b3be5923f1275f0024818e6ae889d881 (patch)
tree333590256ddbeaecbe310c980f133782831eb13e /commands/hugo.go
parentad5703a91712cd245231ba8fdbc49632c794a165 (diff)
Add a "deploy" command
Diffstat (limited to 'commands/hugo.go')
-rw-r--r--commands/hugo.go10
1 files changed, 9 insertions, 1 deletions
diff --git a/commands/hugo.go b/commands/hugo.go
index 0a6b9750c..c6819b054 100644
--- a/commands/hugo.go
+++ b/commands/hugo.go
@@ -204,17 +204,22 @@ func initializeFlags(cmd *cobra.Command, cfg config.Provider) {
"buildWatch",
"cacheDir",
"cfgFile",
+ "confirm",
"contentDir",
"debug",
"destination",
"disableKinds",
+ "dryRun",
+ "force",
"gc",
+ "i18n-warnings",
"layoutDir",
"logFile",
- "i18n-warnings",
+ "maxDeletes",
"quiet",
"renderToMemory",
"source",
+ "target",
"theme",
"themesDir",
"verbose",
@@ -263,6 +268,9 @@ func setValueFromFlag(flags *flag.FlagSet, key string, cfg config.Provider, targ
case "stringSlice":
bv, _ := flags.GetStringSlice(key)
cfg.Set(configKey, bv)
+ case "int":
+ iv, _ := flags.GetInt(key)
+ cfg.Set(configKey, iv)
default:
panic(fmt.Sprintf("update switch with %s", f.Value.Type()))
}