From 2ad60869c2e8d0846672ccb18b2de99c9cf33671 Mon Sep 17 00:00:00 2001 From: pacien Date: Sun, 5 Jan 2020 19:24:50 +0100 Subject: compiler: add option to add tags from n parent directories GitHub: closes #15 --- compiler/src/Config.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'compiler/src/Config.hs') diff --git a/compiler/src/Config.hs b/compiler/src/Config.hs index b9434ba..20bc3bb 100644 --- a/compiler/src/Config.hs +++ b/compiler/src/Config.hs @@ -35,7 +35,7 @@ import Resource (Resolution(..)) data CompilerConfig = CompilerConfig { galleryName :: String , ignoreFiles :: String - , implicitDirectoryTag :: Bool + , tagsFromDirectories :: Int , thumbnailMaxResolution :: Resolution , pictureMaxResolution :: Maybe Resolution } deriving (Generic, Show) @@ -44,7 +44,7 @@ instance FromJSON CompilerConfig where parseJSON = withObject "CompilerConfig" $ \v -> CompilerConfig <$> v .:? "galleryName" .!= "Gallery" <*> v .:? "ignoreFiles" .!= ".^" - <*> v .:? "implicitDirectoryTag" .!= False + <*> v .:? "tagsFromDirectories" .!= 0 <*> v .:? "thumbnailMaxResolution" .!= (Resolution 400 400) <*> v .:? "pictureMaxResolution" -- cgit v1.2.3