Newer
Older
tconfpy / mktconfpy
  1. #!/bin/sh
  2. # Build a release of tconfpy
  3. # $Id: mktconfpy,v 1.106 2004/04/05 08:51:17 tundra Exp $
  4.  
  5. COLOR=
  6. #COLOR=--color
  7. PROGFILE="tconfpy.py"
  8. SUPPFILES="Makefile tconfpy.3 tconfpy-license.txt test-tc.py test-tc.1 setup.py"
  9. DOCFILES="tconfpy.html tconfpy.ps tconfpy.pdf tconfpy.py.ps READ-1ST.txt WHATSNEW.txt tconfpy.txt\
  10. test-tc.html test-tc.ps test-tc.pdf test-tc.py.ps test-tc.txt"
  11.  
  12. # Check Command Line Args
  13.  
  14. DIR="py-tconfpy-"$1
  15.  
  16. if [ $# -ne 1 ]
  17. then
  18. echo "usage: mktconfpy version-number"
  19. exit
  20. fi
  21.  
  22. # Create Working Directory
  23.  
  24. mkdir $DIR
  25.  
  26. # Extract Files From RCS
  27.  
  28. co -r$1 $PROGFILE
  29. chmod 755 $PROGFILE
  30. co $SUPPFILES
  31. co $DOCFILES
  32.  
  33. # Pretty Print The Source Code
  34.  
  35. enscript -Epython -fCourier8 -i2 -L77 -C --mark-wrapped-lines=arrow $COLOR -ptconfpy.py.ps tconfpy.py
  36. enscript -Epython -fCourier8 -i2 -L77 -C --mark-wrapped-lines=arrow $COLOR -ptest-tc.py.ps test-tc.py
  37.  
  38. # Build Documentation
  39.  
  40. rman -fHTML -l tconfpy tconfpy.3 > tconfpy.html
  41. groff -man -Tps tconfpy.3 >tconfpy.ps
  42. gs -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=tconfpy.pdf tconfpy.ps
  43. groff -man -Tascii tconfpy.3 | col -xb >tconfpy.txt
  44.  
  45. rman -fHTML -l tconfpy test-tc.1 > test-tc.html
  46. groff -man -Tps test-tc.1 >test-tc.ps
  47. gs -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=test-tc.pdf test-tc.ps
  48. groff -man -Tascii test-tc.1 | col -xb >test-tc.txt
  49.  
  50. chmod 644 $DOCFILES *txt
  51. gzip *.1
  52. gzip *.3
  53.  
  54. # Build And Save The Release
  55.  
  56. mv $PROGFILE $SUPPFILES $DOCFILES $DIR
  57. mv *.gz $DIR
  58. rlog $PROGFILE >$DIR/CHANGELOG.txt
  59. flip -vm $DIR/*txt
  60.  
  61. tar -czvf $DIR.tar.gz $DIR
  62. mv $DIR.tar.gz Releases
  63.  
  64. # Remove Working Directory
  65. rm -rf $DIR
  66.  
  67.