summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Text/Hakyll/Hakyll.hs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/Text/Hakyll/Hakyll.hs b/src/Text/Hakyll/Hakyll.hs
index 4f36c88..7554972 100644
--- a/src/Text/Hakyll/Hakyll.hs
+++ b/src/Text/Hakyll/Hakyll.hs
@@ -29,5 +29,13 @@ data HakyllConfiguration = HakyllConfiguration
type Hakyll = ReaderT HakyllConfiguration IO
-- | Simplified @ask@ function for the Hakyll monad stack.
+--
+-- Usage would typically be something like:
+--
+-- > doSomething :: a -> b -> Hakyll c
+-- > doSomething arg1 arg2 = do
+-- > siteDirectory' <- askHakyll siteDirectory
+-- > ...
+--
askHakyll :: (HakyllConfiguration -> a) -> Hakyll a
askHakyll = flip liftM ask