#!/bin/sh # CURRENT_DIR=`pwd` DATE=`date "+Last modified: %d %b %Y"` WWWDIR="/users/www/CGAL/Members/Develop/updates" TEMPPAGE="$WWWDIR/temp.html" WWWPAGE="$WWWDIR/index.html" SCRIPTDIR="/projects/CGAL/admin_scripts" DATA_DIR=${SCRIPTDIR}/DATA print_header() { echo "

CGAL Internal Release Page

" echo "This page contains the latest internal release of CGAL" echo "
" } print_newrelease() { cat <<"EOF"

Downloading

Download the latest internal release: EOF echo " " echo "$RELEASE.tar.gz ." if [ -r "$PATCHFILE" ] then echo ""; echo "Or get the patches from the previous release ($PREV_RELEASE)" fi echo '

Differences

' echo "The differences of release $RELEASE with respect to release $PREV_RELEASE are:" if [ -s $DATA_DIR/new_packages ] then echo "
"
echo "

New packages

" cat $DATA_DIR/new_packages echo "
" fi if [ -s $DATA_DIR/new_versions ] then echo "
"
echo "

New versions of existing packages

" cat $DATA_DIR/new_versions echo "
" fi if [ -s $DATA_DIR/removed_packages ] then echo "
"
echo "

Packages that were removed

" cat $DATA_DIR/removed_packages echo "
" fi echo '

Versions

' echo "For release $RELEASE the following packages have been used:" cat <<"EOF"
               Package                  Version
               -------                  -------
EOF
cat $DATA_DIR/latest_versions
echo '
' cat <<"EOF" EOF echo '' echo '
' } print_index() { cat << EOF
  1. Download this release
  2. Differences with previous release
  3. Versions used in this release
  4. Recent submissions page

EOF } if [ ! -r $DATA_DIR/version_info ]; then echo "Cannot open file $DATA_DIR/version_info" exit 1; fi read RELEASE PREV_RELEASE < $DATA_DIR/version_info RELEASE_SIZE="2.6 Mb" rm -f $TEMPPAGE RESULTDIR=/users/www/CGAL/Members/Develop/testsuite/${RELEASE} RESULTPAGE=${RESULTDIR}/announce.html PATCHFILE=${RESULTDIR}/diffs_${RELEASE}.gz echo "patchfile: $PATCHFILE" $SCRIPTDIR/print_cgal_header "CGAL Internal Release Page" > $TEMPPAGE print_header >> $TEMPPAGE print_index >> $TEMPPAGE print_newrelease >> $TEMPPAGE $SCRIPTDIR/print_cgal_trailer >> $TEMPPAGE echo "creating file $RESULTPAGE ..." >&2 cp $TEMPPAGE $RESULTPAGE chmod 664 $RESULTPAGE chgrp cgal $RESULTPAGE echo "creating file $WWWPAGE ..." >&2 rm -f $WWWPAGE mv $TEMPPAGE $WWWPAGE chmod 664 $WWWPAGE chgrp cgal $WWWPAGE