diff options
author | Karl Berry <karl@freefriends.org> | 2010-04-30 18:17:54 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2010-04-30 18:17:54 +0000 |
commit | 5cc722828d1314a5cb3aaf9c00f2f7cad1988c95 (patch) | |
tree | ed4d66c4b46433779ee208db6d5af7b3b3e85b40 /Master/texmf-dist/scripts/pdfjam/pdfpun | |
parent | 0e290b30838946f452aa3ea2fd58654e9cc68b1e (diff) |
pdfjam update
git-svn-id: svn://tug.org/texlive/trunk@18056 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/scripts/pdfjam/pdfpun')
-rwxr-xr-x | Master/texmf-dist/scripts/pdfjam/pdfpun | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/Master/texmf-dist/scripts/pdfjam/pdfpun b/Master/texmf-dist/scripts/pdfjam/pdfpun index eee08a05d33..aea8ff87eec 100755 --- a/Master/texmf-dist/scripts/pdfjam/pdfpun +++ b/Master/texmf-dist/scripts/pdfjam/pdfpun @@ -5,13 +5,14 @@ ## ## Author David Firth (http://go.warwick.ac.uk/dfirth) ## -## This is a simple wrapper for (three runs of) pdfjam, version 2.01 +## This is a simple wrapper for (three runs of) pdfjam, version 2.05 ## ## E_USAGE=64 ## for a command line usage error ## -for arg in "$@"; do - case "$arg" in +for arg +do + case $arg in --batch) printf "pdfpun ERROR: the --batch option is not allowed\n" 1>&2; exit "$E_USAGE" ;; @@ -29,7 +30,7 @@ shift ; ## ## Some (very) minimal checking of the first argument: ## -if test ! -e "$sourceFile" ; +if test ! -f "$sourceFile" ; then printf "pdfpun ERROR: first argument must be a PDF file\n" ; exit $E_USAGE ; @@ -45,21 +46,21 @@ fi ## That's all the argument checking! ## pageSpec="-" ## the default -case "${1}" in +case ${1} in --* | "") ;; *) ## a page spec was given pageSpec="$1" ; shift ;; esac -case "${1}" in +case ${1} in --outfile) outFile="$2" ; - shift 2 ;; + shift; shift ;; *) ;; esac -if test "$outFile" = "" ; +if test -z "$outFile" ; then printf "pdfpun ERROR: no output file specified\n" 1>&2 ; exit "$E_USAGE" ; |