| 1 | #!/bin/shscip-shell filesystem . . `/bin/sh`. |
| 2 | |
| 3 | testscip-shell system . . test. -f /bin/sh5scip-shell filesystem . . `/bin/sh5`. && testscip-shell system . . test. -z "$RUNNING_SH5" \ |
| 4 | && { UNAMES=`unamescip-shell system . . uname. -s`; testscip-shell system . . test. "x$UNAMES" = xULTRIX; } 2>/dev/nullscip-shell filesystem . . `/dev/null`. \ |
| 5 | && { RUNNING_SH5=true; export RUNNING_SH5; exec /bin/sh5scip-shell filesystem . . `/bin/sh5`. $0 ${1+"$@"}; } |
| 6 | unset RUNNING_SH5 |
| 7 | |
| 8 | testscip-shell system . . test. -f /bin/bshscip-shell filesystem . . `/bin/bsh`. && testscip-shell system . . test. -z "$RUNNING_BSH" \ |
| 9 | && { UNAMES=`unamescip-shell system . . uname. -s`; testscip-shell system . . test. "x$UNAMES" = xAIX; } 2>/dev/nullscip-shell filesystem . . `/dev/null`. \ |
| 10 | && { RUNNING_BSH=true; export RUNNING_BSH; exec /bin/bshscip-shell filesystem . . `/bin/bsh`. $0 ${1+"$@"}; } |
| 11 | unset RUNNING_BSH |
| 12 | |
| 13 | progname=`basenamescip-shell system . . basename. $0` |
| 14 | dvired=false |
| 15 | |
| 16 | case $1 in |
| 17 | -r) DVIPS="dvips -x707" |
| 18 | shift;; |
| 19 | *) DVIPS=dvips;; |
| 20 | esac |
| 21 | |
| 22 | case $# in |
| 23 | 0) echoscip-shell system . . echo. "Usage: $progname [-r] files ..." >&2 |
| 24 | exit ;; |
| 25 | esac |
| 26 | |
| 27 | findopt= |
| 28 | dvipsopt= |
| 29 | |
| 30 | for i |
| 31 | do |
| 32 | if [scip-shell system . . `[`. -f $i ] || [scip-shell system . . `[`. -d $i ]; then |
| 33 | findopt="$findopt $i" |
| 34 | else |
| 35 | dvipsopt="$dvipsopt $i" |
| 36 | fi |
| 37 | done |
| 38 | |
| 39 | findscip-shell system . . find. $findopt -name \*.dvi -type f -print | |
| 40 | while truescip-shell system . . true.; do |
| 41 | read i |
| 42 | testscip-shell system . . test. -z "$i" && exit |
| 43 | echoscip-shell system . . echo. "processing file '$i' ..." |
| 44 | $DVIPS $dvipsopt -f "$i" >/dev/nullscip-shell filesystem . . `/dev/null`. |
| 45 | echoscip-shell system . . echo. |
| 46 | done |