#!/bin/bash # # Prepare a new announce concerning mondorescue # # $Id$ # # Syntax: mkannounce [ver-tag] # dname=`dirname $0` prem=`echo $dname |cut -c1` if [ ${prem} == "/" ]; then export TOOLHOME=$dname else export TOOLHOME=${PWD}/$dname fi . $TOOLHOME/common-env . $TOOLHOME/distro-env . $TOOLHOME/ftp-env # We need to get $VER and $TAG if [ "$1" = "" ]; then LAST=`cat ${TOPDIR}/LAST` else LAST=$1 shift fi VER=`echo $LAST | cut -d- -f1` TAG=`echo $LAST | cut -d- -f2` SEARCH=`echo $LAST | cut -c2-` rm -f $TMP/announce.tmp cat > $TMP/announce.tmp << EOF MondoRescue $LAST is now available

I'm happy to announce the availability of a newest version of mondoescue $LAST. Enjoy it as usual!

Now available at ftp://ftp.mondorescue.org/

EOF ssh ${ACCOUNT} "cd $DSTDIR ; find . -name 'm[oi]nd[io]-[0-9]$SEARCH*'" | grep -v 'src.rpm' >> $TMP/announce.tmp cat >> $TMP/announce.tmp << EOF

As usual src.rpm packages are also available in the same directory.

Changes are :

EOF # Generating log files $TOOLHOME/mkchangelog.pl announce mindi $TMP/mindi.ann $TOOLHOME/mkchangelog.pl announce mondo $TMP/mondo.ann echo "

" >> $TMP/announce.tmp sed 's/$/
/' $TMP/mindi.ann >> $TMP/announce.tmp echo "

" >> $TMP/announce.tmp sed 's/$/
/' $TMP/mondo.ann >> $TMP/announce.tmp echo "

" >> $TMP/announce.tmp rm -f $TMP/mindi.ann $TMP/mondo.ann # Store it in DB for Web pages generation $TOOLHOME/mkannounce.pl $TMP/announce.tmp # Then deliver it on the Web #$TOOLHOME/livwww www