Plan 9 from Bell Labs’s /usr/web/sources/contrib/fgb/root/sys/src/cmd/aux/mpage/Contrib/psprint

Copyright © 2021 Plan 9 Foundation.
Distributed under the MIT License.
Download the Plan 9 distribution.


#!/bin/ksh -

STDIN_TMP_FILE=/tmp/psprint.$$

GS=/usr/local/bin/gs
GSLIB=/usr/local/lib/ghostscript/3.53
RM=/bin/rm
#
# define print command (SYSV or BSD ish)
# PRINT="lp -or -s"
PRINT=lpr

if [ $# -eq 0 ]; then
    cat > "${STDIN_TMP_FILE}"
    set "${STDIN_TMP_FILE}"
fi

for i in $* ; do
    ${GS} -sDEVICE=ljet4 -r600 -sOutputFile="|${PRINT}" -q -DNOPAUSE "$i" \
    ${GSLIB}/quit.ps
done

${RM} -f "${STDIN_TMP_FILE}"

exit 0


Bell Labs OSI certified Powered by Plan 9

(Return to Plan 9 Home Page)

Copyright © 2021 Plan 9 Foundation. All Rights Reserved.
Comments to webmaster@9p.io.