aboutsummaryrefslogtreecommitdiff
path: root/man/make-pandoc-man-pages.hs
diff options
context:
space:
mode:
authorJohn MacFarlane <fiddlosopher@gmail.com>2015-03-28 15:36:30 -0700
committerJohn MacFarlane <fiddlosopher@gmail.com>2015-03-28 15:36:30 -0700
commit978ae55b2299f9c2bb186e753c2d89971350c83d (patch)
tree67e20091bcc3fa4af36c38db9cde905dbc3f24d0 /man/make-pandoc-man-pages.hs
parent07cc0079f7775deaff414344687adb5462e24fce (diff)
downloadpandoc-978ae55b2299f9c2bb186e753c2d89971350c83d.tar.gz
make-pandoc-man-pages: fixed to build with new readMarkdown type.
Diffstat (limited to 'man/make-pandoc-man-pages.hs')
-rw-r--r--man/make-pandoc-man-pages.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/man/make-pandoc-man-pages.hs b/man/make-pandoc-man-pages.hs
index 65178a15b..60baff81e 100644
--- a/man/make-pandoc-man-pages.hs
+++ b/man/make-pandoc-man-pages.hs
@@ -1,6 +1,7 @@
{-# LANGUAGE CPP #-}
-- Create pandoc.1 man and pandoc_markdown.5 man pages from README
import Text.Pandoc
+import Text.Pandoc.Error (handleError)
import qualified Text.Pandoc.UTF8 as UTF8
import Data.Char (toUpper)
import Control.Monad
@@ -27,7 +28,7 @@ main = do
unless (null ds1 && null ds2) $ do
rmContents <- UTF8.readFile "README"
- let (Pandoc meta blocks) = normalize $ readMarkdown def rmContents
+ let (Pandoc meta blocks) = normalize $ handleError $ readMarkdown def rmContents
let manBlocks = removeSect [Str "Wrappers"]
$ removeSect [Str "Pandoc's",Space,Str "markdown"] blocks
let syntaxBlocks = extractSect [Str "Pandoc's",Space,Str "markdown"] blocks
@@ -101,4 +102,3 @@ modifiedDependencies file dependencies = do
depModTimes <- mapM getModificationTime dependencies
let modified = zipWith (\dep time -> if time > fileModTime then Just dep else Nothing) dependencies depModTimes
return $ catMaybes modified
-