Fix build for project-template < 0.2

This commit is contained in:
Michael Snoyman 2015-05-17 11:25:12 +03:00
parent ef9322914e
commit 814157a018
2 changed files with 5 additions and 6 deletions

View File

@ -9,14 +9,13 @@ import Control.Monad.Trans.Resource (ResourceT, runResourceT)
import qualified Data.Conduit.List as CL
import qualified Data.ByteString as BS
import Control.Monad.IO.Class (liftIO)
import Data.String (fromString)
mkHsFile :: IO ()
mkHsFile = runResourceT $ sourceDirectory "."
$$ readIt
=$ createTemplate
=$ awaitForever (liftIO . BS.putStr)
-- Reads a filepath from upstream and dumps a pair of (filepath, filecontents)
readIt :: ConduitM FilePath (FilePath, ResourceT IO BS.ByteString) (ResourceT IO) ()
readIt = CL.map $ \i -> (i, liftIO $ BS.readFile i)
where
-- Reads a filepath from upstream and dumps a pair of (filepath, filecontents)
readIt = CL.map $ \i -> (fromString i, liftIO $ BS.readFile i)

View File

@ -1,5 +1,5 @@
name: yesod-bin
version: 1.4.9
version: 1.4.9.1
license: MIT
license-file: LICENSE
author: Michael Snoyman <michael@snoyman.com>