packages feed

file-embed 0.0.0 → 0.0.1

raw patch · 2 files changed

+10/−10 lines, 2 filesPVP ok

version bump matches the API change (PVP)

API changes (from Hackage documentation)

Files

Data/FileEmbed.hs view
@@ -5,8 +5,8 @@     ) where  import Language.Haskell.TH (runQ,-                            Exp(AppE, ListE, LitE, TupE),-                            Lit(IntegerL, StringL),+                            Exp (AppE, ListE, LitE, TupE),+                            Lit (StringL),                             Q,                             runIO) import System.Directory (doesDirectoryExist, doesFileExist,@@ -30,13 +30,13 @@  bsToExp :: B.ByteString -> Q Exp bsToExp bs = do-    pack <- runQ [| B.pack |]-    return $!-        AppE pack .-        ListE .-        map (LitE . IntegerL . fromIntegral) .-        B.unpack $-        bs+    helper <- runQ [| stringToBs |]+    let octets = B.unpack bs+    let chars = map (toEnum . fromEnum) octets+    return $! AppE helper $! LitE $! StringL chars++stringToBs :: String -> B.ByteString+stringToBs = B.pack . map (toEnum . fromEnum)  notHidden :: FilePath -> Bool notHidden ('.':_) = False
file-embed.cabal view
@@ -1,5 +1,5 @@ name:            file-embed-version:         0.0.0+version:         0.0.1 license:         BSD3 license-file:    LICENSE author:          Michael Snoyman <michael@snoyman.com>