packages feed

wikipedia4epub 0.0.9 → 0.0.10

raw patch · 3 files changed

+6/−3 lines, 3 files

Files

src/Wiki4e/Commands/Articles.hs view
@@ -22,8 +22,10 @@ import Wiki4e.Commands.Fetching  wiki4e_sanitizeArticle :: [String] -> FilePath -> FilePath -> IO ()-wiki4e_sanitizeArticle alnk inf ouf = withBinaryFile inf ReadMode (\hi -> do-          withBinaryFile ouf WriteMode (\ho -> do +wiki4e_sanitizeArticle alnk inf ouf = withFile inf ReadMode (\hi -> do+          hSetEncoding hi utf8+          withFile ouf WriteMode (\ho -> do +                  hSetEncoding ho utf8                   c <- hGetContents hi                   let a = sanitizeArticle alnk $ WikiArticleHTML "" c                   hPutStr ho $ waContent a
src/Wiki4e/Commands/Common.hs view
@@ -33,6 +33,7 @@ readFileUTF8 :: FilePath -> IO String readFileUTF8 x = do           h <- openBinaryFile x ReadMode+          hSetEncoding h utf8           c <- hGetContents h           forceList c `seq` hClose h           return c
wikipedia4epub.cabal view
@@ -1,5 +1,5 @@ Name:            wikipedia4epub-Version:         0.0.9+Version:         0.0.10 License:         BSD3 License-File:    LICENSE Homepage:        http://rampa.sk/static/wikipedia4epub.html