summaryrefslogtreecommitdiffstats
path: root/commands
diff options
context:
space:
mode:
Diffstat (limited to 'commands')
-rw-r--r--commands/commands.go2
-rw-r--r--commands/commands_test.go2
2 files changed, 2 insertions, 2 deletions
diff --git a/commands/commands.go b/commands/commands.go
index f835e67a1..c2fb90830 100644
--- a/commands/commands.go
+++ b/commands/commands.go
@@ -250,7 +250,7 @@ func (cc *hugoBuilderCommon) handleFlags(cmd *cobra.Command) {
cmd.Flags().StringP("cacheDir", "", "", "filesystem path to cache directory. Defaults: $TMPDIR/hugo_cache/")
cmd.Flags().BoolP("ignoreCache", "", false, "ignores the cache directory")
cmd.Flags().StringP("destination", "d", "", "filesystem path to write files to")
- cmd.Flags().StringP("theme", "t", "", "theme to use (located in /themes/THEMENAME/)")
+ cmd.Flags().StringSliceP("theme", "t", []string{}, "themes to use (located in /themes/THEMENAME/)")
cmd.Flags().StringP("themesDir", "", "", "filesystem path to themes directory")
cmd.Flags().StringVarP(&cc.baseURL, "baseURL", "b", "", "hostname (and path) to the root, e.g. http://spf13.com/")
cmd.Flags().Bool("enableGitInfo", false, "add Git revision, date and author info to the pages")
diff --git a/commands/commands_test.go b/commands/commands_test.go
index a8cc1d927..57c9d6005 100644
--- a/commands/commands_test.go
+++ b/commands/commands_test.go
@@ -104,7 +104,7 @@ func TestCommandsPersistentFlags(t *testing.T) {
assert.Equal("/tmp/mydestination", cfg.GetString("publishDir"))
assert.Equal("mycontent", cfg.GetString("contentDir"))
assert.Equal("mylayouts", cfg.GetString("layoutDir"))
- assert.Equal("mytheme", cfg.GetString("theme"))
+ assert.Equal([]string{"mytheme"}, cfg.GetStringSlice("theme"))
assert.Equal("mythemes", cfg.GetString("themesDir"))
assert.Equal("https://example.com/b/", cfg.GetString("baseURL"))