blob: 6d932064bdf2038b25815f4ddc0d12165389b297 [file] [log] [blame]
Fred Drakefcf275e1998-03-03 17:22:44 +00001#! /bin/sh
2#
3# script to create the latex source distribution
4# * should be modified to get the Python version number automatically
5# from the Makefile or someplace.
6#
7# usage:
Fred Drakef2fa1e21998-05-11 18:52:24 +00008# ./mktarball.sh release [tag]
Fred Drakefcf275e1998-03-03 17:22:44 +00009#
10# without [tag]: generate from the current version that's checked in
11# (*NOT* what's in the current directory!)
12#
13# with [tag]: generate from the named tag
14
Fred Drakef2fa1e21998-05-11 18:52:24 +000015RELEASE=$1; shift
Fred Drakefcf275e1998-03-03 17:22:44 +000016
17TEMPDIR=tmp.$$
18MYDIR=`pwd`
19
20TAG="$1"
21
Fred Drakee3ae5191998-04-13 21:55:56 +000022mkdirhier $TEMPDIR/Python-$RELEASE/Doc || exit $?
Fred Drakefcf275e1998-03-03 17:22:44 +000023if [ "$TAG" ] ; then
Fred Drakee3ae5191998-04-13 21:55:56 +000024 cvs export -r $TAG -d $TEMPDIR/Python-$RELEASE/Doc python/dist/src/Doc \
Fred Drake2888bf61998-03-05 16:31:22 +000025 || exit $?
Fred Drakefcf275e1998-03-03 17:22:44 +000026else
Fred Drakee3ae5191998-04-13 21:55:56 +000027 cvs checkout -d $TEMPDIR/Python-$RELEASE/Doc python/dist/src/Doc || exit $?
Fred Drakefcf275e1998-03-03 17:22:44 +000028 rm -r `find $TEMPDIR -name CVS -print` || exit $?
29fi
30
Fred Drakef2fa1e21998-05-11 18:52:24 +000031rm -f `find $TEMPDIR -name .cvsignore -print`
Fred Drake45e564d1998-03-10 14:00:55 +000032
Fred Drakee3ae5191998-04-13 21:55:56 +000033rm -f $TEMPDIR/Python-$RELEASE/Doc/ref/ref.pdf
34rm -f $TEMPDIR/Python-$RELEASE/Doc/ref/ref.ps
Fred Drake45e564d1998-03-10 14:00:55 +000035
Fred Drakefcf275e1998-03-03 17:22:44 +000036cd $TEMPDIR
37
Fred Drake72dd58d1998-05-11 21:08:39 +000038(tar cf - Python-$RELEASE | gzip -9 >$MYDIR/latex-$RELEASE.tgz) || exit $?
Fred Drakefcf275e1998-03-03 17:22:44 +000039cd $MYDIR
40rm -r $TEMPDIR || exit $?
41
42exit 0