blob: 0703d11000c756351ec2ac146b920ef1b878e890 [file] [log] [blame]
Fred Drake692565c2000-10-19 05:54:51 +00001#! /bin/sh
2
3# Script to push docs from my development area to SourceForge, where the
4# update-docs.sh script unpacks them into their final destination.
5
Fred Drake3f4e7172001-03-02 21:05:58 +00006TARGET=python.sourceforge.net:/home/users/fdrake/tmp
Fred Drake827bb9f2000-11-30 07:38:59 +00007
Fred Drake3f4e7172001-03-02 21:05:58 +00008ADDRESSES='python-dev@python.org doc-sig@python.org python-list@python.org'
9
Fred Drake3f4e7172001-03-02 21:05:58 +000010EXPLANATION=''
11
12if [ "$1" = '-m' ] ; then
13 EXPLANATION="$2"
14 shift 2
15elif [ "$1" ] ; then
16 EXPLANATION="`cat $1`"
17 shift 1
Fred Drake827bb9f2000-11-30 07:38:59 +000018fi
19
Fred Drake692565c2000-10-19 05:54:51 +000020START="`pwd`"
21MYDIR="`dirname $0`"
22cd "$MYDIR"
23MYDIR="`pwd`"
Fred Drake692565c2000-10-19 05:54:51 +000024
Fred Drake7ceab732000-10-24 19:59:55 +000025cd ..
Fred Drake3f4e7172001-03-02 21:05:58 +000026
27# now in .../Doc/
28make --no-print-directory || exit $?
29make --no-print-directory bziphtml || exit $?
Fred Drake692565c2000-10-19 05:54:51 +000030RELEASE=`grep '^RELEASE=' Makefile | sed 's|RELEASE=||'`
Fred Drake3f4e7172001-03-02 21:05:58 +000031scp "html-$RELEASE.tar.bz2" $TARGET/python-docs-update.tar.bz2 || exit $?
32scp tools/update-docs.sh $TARGET/update-docs.sh || exit $?
33ssh python.sourceforge.net 'tmp/update-docs.sh && rm tmp/update-docs.sh' || exit $?
34
35Mail -s '[development doc updates]' $ADDRESSES <<EOF
36The development version of the documentation has been updated:
37
38 http://python.sourceforge.net/devel-docs/
39
40$EXPLANATION
41EOF
42exit $?