yst 0.7.1.2 → 0.7.1.3
raw patch · 3 files changed
+15/−16 lines, 3 filesdep −old-localedep −old-timedep −unordered-containersdep ~aesondep ~time
Dependencies removed: old-locale, old-time, unordered-containers
Dependency ranges changed: aeson, time
Files
- Yst/Types.hs +7/−10
- changelog +5/−0
- yst.cabal +3/−6
Yst/Types.hs view
@@ -21,18 +21,15 @@ module Yst.Types where import Data.Char-import qualified Data.HashMap.Strict as H import Data.Time+import Data.String (fromString) import qualified Data.Text as T import Text.StringTemplate import Data.Aeson+import Data.Aeson.KeyMap (KeyMap, foldrWithKey, insert) import qualified Data.Map as M import Data.Scientific (coefficient, base10Exponent) import Control.Monad-#if MIN_VERSION_time(1,5,0)-#else-import System.Locale ( defaultTimeLocale )-#endif data Site = Site { siteTitle :: String@@ -137,11 +134,11 @@ | otherwise = return $ NString $ show n parseJSON _ = return $ NNil -handleMerges :: H.HashMap T.Text Value -> H.HashMap T.Text Value-handleMerges = H.foldrWithKey go H.empty- where go k (Object h) m | isMerge k = H.foldrWithKey go m h- go k v m = H.insert k v m- isMerge k = k == T.pack "<<"+handleMerges :: KeyMap Value -> KeyMap Value+handleMerges = foldrWithKey go mempty+ where go k (Object h) m | isMerge k = foldrWithKey go m h+ go k v m = insert k v m+ isMerge k = k == fromString "<<" instance ToJSON Node where toJSON (NDate s) = toJSON (NString $ formatTime defaultTimeLocale "%x" s)
changelog view
@@ -1,3 +1,8 @@+yst 0.7.1.3 (released 16 Jul 2022)++ * Remove support for old versions of time (#54).+ * Require aeson >= 2 and update code (#55).+ yst 0.7.1.2 (released 12 Aug 2021) * Use latest HStringTemplate so we can build with GHC 9.
yst.cabal view
@@ -1,6 +1,6 @@ cabal-version: 2.2 name: yst-version: 0.7.1.2+version: 0.7.1.3 build-type: Simple synopsis: Builds a static website from templates and data in YAML or CSV files.@@ -57,19 +57,16 @@ Paths_yst autogen-modules: Paths_yst build-depends: base >=3 && < 5,- unordered-containers, HStringTemplate >= 0.8.8, csv,- aeson >= 1.0,+ aeson >= 2.0, yaml, text, scientific >= 0.2, filepath, containers, directory,- time,- old-locale,- old-time,+ time >= 1.5, parsec, lucid >= 2.9, pandoc >= 2.14,