Created
May 22, 2009 09:31
-
-
Save MikeRalphson/116030 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# $1 should be the input textfile | |
# $2 should be the output pdf filename | |
# $3 should be the email address to send to | |
if [ "$2" = "" ] | |
then | |
echo Usage: textfile pdfname email | |
else | |
a2ps --landscape --columns=1 -l 136 -L 63 --medium=a4 --output=/usra/dfpout/$2.ps $1 | |
pstops -w0 -h0 1:0R\(0in,20.9903cm\) /usra/dfpout/$2.ps > /usra/dfpout/rotated.ps | |
ps2pdf13 -g8420x5950 /usra/dfpout/rotated.ps /usra/dfpout/$2 | |
fi | |
if [ "$3" != "" ] | |
then | |
mpack -s"$1" /usra/dfpout/$2 $3 | |
fi | |
rm -f /usra/dfpout/$2.ps |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment