aboutsummaryrefslogtreecommitdiff
path: root/Types.hs
diff options
context:
space:
mode:
Diffstat (limited to 'Types.hs')
-rw-r--r--Types.hs11
1 files changed, 7 insertions, 4 deletions
diff --git a/Types.hs b/Types.hs
index 992c866..a3b65cd 100644
--- a/Types.hs
+++ b/Types.hs
@@ -56,7 +56,7 @@ data SiteState = SiteState
, _sourceDirs :: [FilePath] -- ^ Path to page source data
, _notSourceDirs :: [FilePath] -- ^ Subdirectories of source dirs where pages should not be sourced
, _tagMetaFile :: FilePath -- ^ Name of the "tag metadata" files to find in the source directories.
- , _templateDir :: FilePath -- ^ Path to template directory
+ , _templateDirs :: [FilePath] -- ^ Paths to template directories
, _defaultTemplate :: FilePath -- ^ Name of the default template
, _redirectTemplate :: FilePath -- ^ Name of the template for redirect pages
, _tagTemplate :: FilePath -- ^ Name of the template for category pages
@@ -113,10 +113,12 @@ siteOptions' = do
<> help "Name of files with tag metadata"
<> value "tag-metadata.yml"
<> showDefault
- _templateDir <-
- strOption
+ _templateDirs <-
+ many . strOption
$ long "template-directory"
- <> help "Path to the directory with templates"
+ <> short 't'
+ <> help
+ "Path to the directory with templates (possibly multiple paths)"
<> value "templates"
<> showDefault
_defaultTemplate <-
@@ -162,6 +164,7 @@ siteOptions' = do
++ Y.prettyPrintParseException err
in fmap (foldl objMerge Y.Null . map processKeyVal) . many . strOption
$ long "extra-metadata"
+ <> short 'e'
<> help
"Extra metadata to add to pages rendering in YAML format. May be specified multiple times."
_urlBase <-