summaryrefslogtreecommitdiff
path: root/src/Hakyll/Commands.hs
diff options
context:
space:
mode:
authorSamuel Tardieu <sam@rfc1149.net>2013-03-24 21:47:05 +0100
committerSamuel Tardieu <sam@rfc1149.net>2013-03-24 21:52:21 +0100
commit543cba90f6efba8508d2feb3377b1a9f5f428c1a (patch)
tree747c32d1e0c267a1c074971bf5097eacced007a5 /src/Hakyll/Commands.hs
parent6c8fda2c00bd14bf75c9fa1b98b09e283711a706 (diff)
downloadhakyll-543cba90f6efba8508d2feb3377b1a9f5f428c1a.tar.gz
Allow overriding the `deploy` command with Haskell code
By overriding `deploySite` with a `Configuration -> IO ()` code, the user can execute Haskell code to deploy the site rather than shell code. The default behaviour honors the `deployCommand` configuration field and is backward compatible.
Diffstat (limited to 'src/Hakyll/Commands.hs')
-rw-r--r--src/Hakyll/Commands.hs5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/Hakyll/Commands.hs b/src/Hakyll/Commands.hs
index 4c60783..6e0b9f2 100644
--- a/src/Hakyll/Commands.hs
+++ b/src/Hakyll/Commands.hs
@@ -14,7 +14,6 @@ module Hakyll.Commands
--------------------------------------------------------------------------------
import System.Exit (ExitCode (ExitSuccess), exitWith)
-import System.Process (system)
--------------------------------------------------------------------------------
@@ -109,9 +108,7 @@ server _ _ = previewServerDisabled
--------------------------------------------------------------------------------
-- | Upload the site
deploy :: Configuration -> IO ()
-deploy conf = do
- _ <- system $ deployCommand conf
- return ()
+deploy conf = deploySite conf conf
--------------------------------------------------------------------------------