diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/Network/Hakyll/SimpleServer.hs | 5 | ||||
-rw-r--r-- | src/Text/Hakyll/Page.hs | 2 | ||||
-rw-r--r-- | src/Text/Hakyll/Render.hs | 3 | ||||
-rw-r--r-- | src/Text/Hakyll/Renderable.hs | 1 | ||||
-rw-r--r-- | src/Text/Hakyll/Renderables.hs | 1 |
5 files changed, 4 insertions, 8 deletions
diff --git a/src/Network/Hakyll/SimpleServer.hs b/src/Network/Hakyll/SimpleServer.hs index 4baa466..f98c295 100644 --- a/src/Network/Hakyll/SimpleServer.hs +++ b/src/Network/Hakyll/SimpleServer.hs @@ -6,7 +6,7 @@ module Network.Hakyll.SimpleServer import Prelude hiding (log) import Network -import Control.Monad (forever, mapM_) +import Control.Monad (forever) import Control.Monad.Reader (ReaderT, runReaderT, ask, liftIO) import System.IO import System.Directory (doesFileExist, doesDirectoryExist) @@ -202,10 +202,9 @@ simpleServer port root = do -- When a client connects, respond in a separate thread. listen socket = do (handle, _, _) <- accept socket forkIO (runReaderT (respond handle) config) - return () -- Handle logging in a separate thread - forkIO (log logChan) + _ <- forkIO (log logChan) writeChan logChan $ "Starting hakyll server on port " ++ show port ++ "..." socket <- listenOn (PortNumber port) diff --git a/src/Text/Hakyll/Page.hs b/src/Text/Hakyll/Page.hs index 652a1c6..0c912a9 100644 --- a/src/Text/Hakyll/Page.hs +++ b/src/Text/Hakyll/Page.hs @@ -13,7 +13,7 @@ import Data.Maybe (fromMaybe) import Control.Parallel.Strategies (rdeepseq, ($|)) import Control.Monad.Reader (liftIO) -import System.FilePath (FilePath, takeExtension) +import System.FilePath (takeExtension) import System.IO import Text.Hakyll.Hakyll (Hakyll) diff --git a/src/Text/Hakyll/Render.hs b/src/Text/Hakyll/Render.hs index 870c953..c529d04 100644 --- a/src/Text/Hakyll/Render.hs +++ b/src/Text/Hakyll/Render.hs @@ -10,11 +10,10 @@ module Text.Hakyll.Render , css ) where -import Control.Monad (unless, mapM) +import Control.Monad (unless) import Control.Monad.Reader (liftIO) import System.Directory (copyFile) -import System.IO import Text.Hakyll.Hakyll (Hakyll) import Text.Hakyll.Context (ContextManipulation) diff --git a/src/Text/Hakyll/Renderable.hs b/src/Text/Hakyll/Renderable.hs index cafdb3c..bb4f71f 100644 --- a/src/Text/Hakyll/Renderable.hs +++ b/src/Text/Hakyll/Renderable.hs @@ -3,7 +3,6 @@ module Text.Hakyll.Renderable ) where import Text.Hakyll.Hakyll (Hakyll) -import System.FilePath (FilePath) import Text.Hakyll.Context (Context) -- | A class for datatypes that can be rendered to pages. diff --git a/src/Text/Hakyll/Renderables.hs b/src/Text/Hakyll/Renderables.hs index 19f25b5..780f1e4 100644 --- a/src/Text/Hakyll/Renderables.hs +++ b/src/Text/Hakyll/Renderables.hs @@ -6,7 +6,6 @@ module Text.Hakyll.Renderables ) where import Text.Hakyll.Hakyll (Hakyll) -import System.FilePath (FilePath) import qualified Data.Map as M import Text.Hakyll.Page import Text.Hakyll.Renderable |