diff options
author | Gregor Kleen <gkleen@yggdrasil.li> | 2015-08-03 18:31:38 +0200 |
---|---|---|
committer | Gregor Kleen <gkleen@yggdrasil.li> | 2015-08-03 18:31:38 +0200 |
commit | 928b92515f2ab21bc7bb74fe65cdaaf40e81e57c (patch) | |
tree | ec69859bdb1f24e96aad3967b2ab77b2ec917592 | |
parent | d80e220029bfe495c86d6e9abe187d1a940c7dfe (diff) | |
download | dirty-haskell.org-928b92515f2ab21bc7bb74fe65cdaaf40e81e57c.tar dirty-haskell.org-928b92515f2ab21bc7bb74fe65cdaaf40e81e57c.tar.gz dirty-haskell.org-928b92515f2ab21bc7bb74fe65cdaaf40e81e57c.tar.bz2 dirty-haskell.org-928b92515f2ab21bc7bb74fe65cdaaf40e81e57c.tar.xz dirty-haskell.org-928b92515f2ab21bc7bb74fe65cdaaf40e81e57c.zip |
minor code cleanup
-rw-r--r-- | src/Site.hs | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Site.hs b/src/Site.hs index dde7047..1facff6 100644 --- a/src/Site.hs +++ b/src/Site.hs | |||
@@ -13,7 +13,7 @@ import Data.Default | |||
13 | import Text.Pandoc.Options (WriterOptions(..), ObfuscationMethod(..)) | 13 | import Text.Pandoc.Options (WriterOptions(..), ObfuscationMethod(..)) |
14 | import Control.Applicative (Alternative(..), Applicative(..)) | 14 | import Control.Applicative (Alternative(..), Applicative(..)) |
15 | 15 | ||
16 | import System.FilePath (replaceExtension) | 16 | import System.FilePath (takeBaseName, (</>), (<.>)) |
17 | 17 | ||
18 | main :: IO () | 18 | main :: IO () |
19 | main = hakyllWith config $ do | 19 | main = hakyllWith config $ do |
@@ -46,7 +46,7 @@ main = hakyllWith config $ do | |||
46 | >>= relativizeUrls | 46 | >>= relativizeUrls |
47 | 47 | ||
48 | let | 48 | let |
49 | tags' = tags { tagsMakeId = fromFilePath . (`replaceExtension` "rss") . toFilePath . tagsMakeId tags} | 49 | tags' = tags { tagsMakeId = fromFilePath . (\b -> "rss" </> b <.> "rss") . takeBaseName . toFilePath . tagsMakeId tags} |
50 | 50 | ||
51 | tagsRules tags' $ \tag pattern -> do | 51 | tagsRules tags' $ \tag pattern -> do |
52 | route idRoute | 52 | route idRoute |