diff options
author | roktas <roktas@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2006-10-27 12:25:11 +0000 |
---|---|---|
committer | roktas <roktas@788f1e2b-df1e-0410-8736-df70ead52e1b> | 2006-10-27 12:25:11 +0000 |
commit | 469a36d8453d49a8d339f1b8d6865e3a4860bdf2 (patch) | |
tree | eb149a65f357fba8510dd10324df7dad6cc0efae /markdown2pdf | |
parent | b7784aa4115bb93d7f513c79ed029a5a41f3b4d5 (diff) | |
download | pandoc-469a36d8453d49a8d339f1b8d6865e3a4860bdf2.tar.gz |
Minor corrections.
git-svn-id: https://pandoc.googlecode.com/svn/trunk@19 788f1e2b-df1e-0410-8736-df70ead52e1b
Diffstat (limited to 'markdown2pdf')
-rw-r--r-- | markdown2pdf | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/markdown2pdf b/markdown2pdf index bea336a07..6ca931fdd 100644 --- a/markdown2pdf +++ b/markdown2pdf @@ -21,7 +21,7 @@ for option; do optarg=$(expr "x$option" : 'x[^=]*=\(.*\)') case $option in -h | --h | --help ) - help=yes + help=1 shift ;; -o | --o | --output ) prev=outfile @@ -35,10 +35,10 @@ for option; do esac done -if [ "$help" = "yes" ]; then - echo "Usage: $0 [-o|--output output-file] [input-file]" +[ -z "$help" ] || { + echo >&2 "Usage: $0 [-o|--output output-file] [input-file]" exit 0 -fi +} infile=$1 if [ -z "$outfile" ]; then @@ -69,7 +69,7 @@ iconv -t utf-8 $infile | pandoc -w latex -s > $TEMP/$BASE.tex ) || exit $? is_target_exists= -if [ -f $BASE.pdf ]; then +if [ -f $outfile ]; then is_target_exists=1 fi |