From 365e867a88c4c5cc78e101a9e0e550974acb0507 Mon Sep 17 00:00:00 2001 From: Ben Gras Date: Wed, 18 Apr 2007 11:42:48 +0000 Subject: [PATCH] Some features for the automatic image build. --- tools/release.sh | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/tools/release.sh b/tools/release.sh index 4e276e687..ee6822534 100755 --- a/tools/release.sh +++ b/tools/release.sh @@ -95,11 +95,13 @@ SVNREV="" REVTAG="" PACKAGES=1 -while getopts "pchu?r:" c +FILENAMEOUT="" + +while getopts "s:pchu?r:f:" c do case "$c" in \?) - echo "Usage: $0 [-p] [-c] [-h] [-r ] [-u]" >&2 + echo "Usage: $0 [-p] [-c] [-h] [-r ] [-u] [-f ] [-s ]" >&2 exit 1 ;; h) @@ -123,6 +125,11 @@ do HDEMU=1 USB=1 ;; + f) + FILENAMEOUT="$OPTARG" + ;; + s) USERNAME="--username=$OPTARG" + ;; esac done @@ -214,7 +221,7 @@ then fi echo " * Cleanup old files" -rm -rf $RELEASEDIR $IMG $IMAGE $ROOTIMAGE $IMGBZ $CDFILES image* +rm -rf $RELEASEDIR $IMG $IMAGE $ROOTIMAGE $CDFILES image* mkdir -p $CDFILES || exit mkdir -p $RELEASEDIR mkfs -B $BS -b $ROOTBLOCKS $TMPDISK3 || exit @@ -280,9 +287,9 @@ if [ "$COPY" -ne 1 ] then echo " * Doing new svn export" REPO=https://gforge.cs.vu.nl/svn/minix/trunk/$SRC - REVISION="`svn info $SVNREV $REPO | grep '^Revision: ' | awk '{ print $2 }'`" + REVISION="`svn info $USERNAME $SVNREV $REPO | grep '^Revision: ' | awk '{ print $2 }'`" echo "Doing export of revision $REVISION from $REPO." - ( cd $RELEASEDIR/usr && svn export -r$REVISION $REPO ) + ( cd $RELEASEDIR/usr && svn $USERNAME export -r$REVISION $REPO ) REVTAG=r$REVISION echo " @@ -303,8 +310,6 @@ if [ "$USB" -ne 0 ]; then else IMG=${IMG_BASE}_${REVTAG}.iso fi -IMGBZ=${IMG}.bz2 -echo "Making $IMGBZ" echo " * Fixups for owners and modes of dirs and files" chown -R bin $RELEASEDIR/usr/$SRC @@ -403,3 +408,7 @@ else partition -m $IMG 0 81:$isosects 81:$ROOTSECTS 81:$USRSECTS fi fi + +if [ "$FILENAMEOUT" ] +then echo "$IMG" >$FILENAMEOUT +fi -- 2.44.0