summaryrefslogtreecommitdiff
path: root/src/Hakyll/Core/Writable.hs
diff options
context:
space:
mode:
Diffstat (limited to 'src/Hakyll/Core/Writable.hs')
-rw-r--r--src/Hakyll/Core/Writable.hs5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/Hakyll/Core/Writable.hs b/src/Hakyll/Core/Writable.hs
index a93903f..db53d9a 100644
--- a/src/Hakyll/Core/Writable.hs
+++ b/src/Hakyll/Core/Writable.hs
@@ -8,7 +8,9 @@ module Hakyll.Core.Writable
) where
import System.Directory (copyFile)
+import Data.Word (Word8)
+import qualified Data.ByteString as SB
import Data.Binary (Binary)
import Data.Typeable (Typeable)
@@ -21,6 +23,9 @@ class Writable a where
instance Writable [Char] where
write = writeFile
+instance Writable [Word8] where
+ write p = SB.writeFile p . SB.pack
+
-- | Newtype construct around 'FilePath' which will copy the file directly
--
newtype CopyFile = CopyFile {unCopyFile :: FilePath}