diff --git a/make-pages/BuilderQQ.hs b/make-pages/BuilderQQ.hs index 2b83acf..f0d0609 100644 --- a/make-pages/BuilderQQ.hs +++ b/make-pages/BuilderQQ.hs @@ -1,5 +1,5 @@ {-# LANGUAGE TemplateHaskell #-} -module BuilderQQ (b) where +module BuilderQQ (b, Builder, toLazyText, fromText, fromString, fromChar) where import Data.Char (isLower, isSpace, isDigit, isAlphaNum) import Language.Haskell.TH @@ -176,3 +176,6 @@ pattern c :. t <- (Text.uncons -> Just (c, t)) where c :. t = Text.cons c t {-# COMPLETE NilT, (:.) :: Text #-} + +fromChar :: Char -> Builder +fromChar = singleton diff --git a/make-pages/Depend.hs b/make-pages/Depend.hs index e3a339f..da1efba 100644 --- a/make-pages/Depend.hs +++ b/make-pages/Depend.hs @@ -9,7 +9,6 @@ import Info hiding (Text) import Data.Maybe (fromMaybe) import Data.Text.Lazy (Text) -import Data.Text.Lazy.Builder (Builder, toLazyText, fromString) import System.FilePath diff --git a/make-pages/GalleryPage.hs b/make-pages/GalleryPage.hs index 673c733..f6f8116 100644 --- a/make-pages/GalleryPage.hs +++ b/make-pages/GalleryPage.hs @@ -4,7 +4,6 @@ import Control.Exception import Data.Function (on, (&)) import Data.List (sortBy, groupBy) import qualified Data.Text.Lazy as Lazy -import Data.Text.Lazy.Builder (Builder, toLazyText) import System.FilePath ((), takeDirectory) import BuilderQQ diff --git a/make-pages/IndexPage.hs b/make-pages/IndexPage.hs index e523e3c..61b783d 100644 --- a/make-pages/IndexPage.hs +++ b/make-pages/IndexPage.hs @@ -1,7 +1,6 @@ module IndexPage (make) where import qualified Data.Text.Lazy as Lazy -import Data.Text.Lazy.Builder (Builder, toLazyText) import BuilderQQ import Info diff --git a/make-pages/SinglePage.hs b/make-pages/SinglePage.hs index eec36e4..a5e1627 100644 --- a/make-pages/SinglePage.hs +++ b/make-pages/SinglePage.hs @@ -8,7 +8,6 @@ import Records () import Control.Exception import qualified Data.Text as Strict import qualified Data.Text.Lazy as Lazy -import Data.Text.Lazy.Builder (Builder, toLazyText) import Data.Time (formatTime, defaultTimeLocale) import Data.Maybe (fromMaybe) import qualified Data.Char as Char