Newer
Older
nohtml / mknohtml
@tundra tundra on 5 May 2003 1 KB Initial revision
#!/bin/sh
# Build a release of nohtml
# $Id: mknohtml,v 1.1 2003/05/05 21:32:41 tundra Exp $

COLOR=
#COLOR=--color
PROGFILE="nohtml.py"
SUPPFILES="Makefile nohtml.1 nohtml-license.txt"
DOCFILES="nohtml.html nohtml.ps nohtml.pdf nohtml.py.ps  READ-1ST.txt WHATSNEW.txt nohtml.txt"

# Check Command Line Args

DIR="nohtml-"$1

if [ $# -ne 1 ]
    then
	echo "usage: mknohtml version-number"
	exit
fi

# Create Working Directory 

mkdir $DIR

# Extract Files From RCS

co -r$1 $PROGFILE
chmod 755 $PROGFILE
co $SUPPFILES
co $DOCFILES

# Pretty Print The Source Code

enscript -Epython -fCourier8 -i2 -L77 -C --mark-wrapped-lines=arrow $COLOR -pnohtml.py.ps nohtml.py

# Build Documentation

rman -fHTML -l nohtml nohtml.1 > nohtml.html
groff -man -Tps nohtml.1 >nohtml.ps
gs -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=nohtml.pdf nohtml.ps
groff -man -Tascii nohtml.1 | col -xb >nohtml.txt
chmod 644 $DOCFILES *txt
gzip *.1

# Build And Save The Release

mv $PROGFILE $SUPPFILES $DOCFILES $DIR
mv *.gz $DIR
rlog $PROGFILE >$DIR/CHANGELOG.txt
flip -vm $DIR/*txt
tar -czvf $DIR.tar.gz $DIR
mv $DIR.tar.gz Releases

# Remove Working Directory
rm -rf $DIR