Sorry for that, here's a revised version of the patch. fre 2008-05-23 klockan 02:42 +0300 skrev Yair K.: > On Thursday 22 May 2008 19:40:24 Kristian Söderholm wrote: > > Hi again, > > > > I made the script rename any previously generated packages based on date > > and index. The changes are attached as a diff. > > > > Regards, > > Kristian > > The patch uses 'local', which isn't portable (e.g. Ubuntu systems use dash, > which I believe doesn't support it[1]). (Thanks for Ionic for checking it out > first). > > [1] https://bugs.launchpad.net/ubuntu/+source/dash/+bug/139097 > > Yours, > Yair K. > > _______________________________________________ > oss-devel mailing list > oss-devel@mailman.opensound.com > http://mailman.opensound.com/mailman/listinfo/oss-devel
--- mkdeb.sh.orig 2008-05-22 18:24:42.000000000 +0200 +++ mkdeb.sh 2008-05-22 18:33:46.000000000 +0200 @@ -6,6 +6,7 @@ VERSION=`sh showversion.sh` FILENAME="${NAME}_${VERSION}-${RELEASE}_${ARCHITECTURE}.deb" +FILENAME_BACKUP="${FILENAME%.deb}_`date +%Y%m%d`.INDEX.deb" echo "2.0" > debian-binary cat > control <<END @@ -31,5 +32,28 @@ (cd prototype; tar cfz ../data.tar.gz ./*) -ar r $FILENAME debian-binary control.tar.gz data.tar.gz +backup="$FILENAME" +index=-1 +while [ -f "$backup" ]; do + index=$(($index + 1)) + eval backup=`echo $FILENAME_BACKUP | sed 's/INDEX/$index/'` +done + +if [ "$index" -gt "-1" ]; then + for backup_target_index in `seq $index -1 0`; do + eval backup_target="`echo $FILENAME_BACKUP | sed 's/INDEX/$backup_target_index/'`" + + if [ "$backup_target_index" -gt "0" ]; then + backup_source_index=$(($backup_target_index - 1)) + eval backup_source="`echo $FILENAME_BACKUP | sed 's/INDEX/$backup_source_index/'`" + else + backup_source="$FILENAME" + fi + + mv "$backup_source" "$backup_target" + done +fi + +ar r "$FILENAME" debian-binary control.tar.gz data.tar.gz rm -f debian-binary control.tar.gz data.tar.gz +
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ oss-devel mailing list oss-devel@mailman.opensound.com http://mailman.opensound.com/mailman/listinfo/oss-devel