diff options
Diffstat (limited to 'markdown2latex')
-rw-r--r-- | markdown2latex | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/markdown2latex b/markdown2latex index 3f78adbda..59a467fbc 100644 --- a/markdown2latex +++ b/markdown2latex @@ -1,7 +1,11 @@ #!/bin/sh -e # converts markdown to latex -[ -n "$(which pandoc)" ] || { - echo >&2 "You need 'pandoc' to use this program!" - exit 1 -} + +for p in pandoc; do + which $p >/dev/null 2>&1 || { + echo >&2 "You need '$p' to use this program!" + exit 1 + } +done + iconv -t utf-8 $* | pandoc $PANDOC_OPTS -w latex -s | iconv -f utf-8 |