Plan 9 from Bell Labs’s /usr/web/sources/plan9/sys/src/cmd/gs/lib/pdf2dsc

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


#! /bin/sh
# $Id: pdf2dsc,v 1.6 2004/08/04 00:55:46 giles Exp $

# psf2dsc: generates an index of a PDF file.
#
# Yves Arrouye <arrouye@debian.org>, 1996.
# 2000-05-18 lpd <ghost@aladdin.com> added -dSAFER

# This definition is changed on install to match the
# executable name set in the makefile
GS_EXECUTABLE=gs

me=`basename $0`

usage() {
    >&2 echo usage: $me "pdffile [ dscfile ]"
    exit 1
}

if [ $# -gt 2 ]
then
    usage
fi

pdffile=$1
dscfile=$2
: ${dscfile:=`echo $pdffile | sed 's,\.[^/.]*,,'`.dsc}

exec $GS_EXECUTABLE -q -dNODISPLAY -dSAFER -dDELAYSAFER\
    -sPDFname="$pdffile" -sDSCname="$dscfile" pdf2dsc.ps -c quit

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.