]> Zhao Yanbai Git Server - minix.git/commitdiff
release.sh: SVN to GIT updates 36/1036/3
authorDavid van Moolenbroek <david@minix3.org>
Fri, 11 Oct 2013 18:38:45 +0000 (20:38 +0200)
committerDavid van Moolenbroek <david@minix3.org>
Mon, 14 Oct 2013 14:39:13 +0000 (16:39 +0200)
- exclude .git instead of .svn when using local source (-c);
- put the git tag (or "copy") in /etc/version rather than something
  outdated related to SVN;
- remove SVN-specific -s flag (suggested by Erik).

Change-Id: Ia35eb95c39ae93ebae5638c9dd7847428593b813

releasetools/release.sh

index b271178478b29708ae27f391518e86e0d031e044..5da125b752615021f9528199e6d4bb284d38a166 100755 (executable)
@@ -75,11 +75,11 @@ fi
 
 FILENAMEOUT=""
 
-while getopts "b:j:ls:pmMch?f:L:e:" c
+while getopts "b:j:lpmMch?f:L:e:" c
 do
        case "$c" in
        \?)
-               echo "Usage: $0 [-l] [-p] [-c] [-m] [-M] [-f <filename>] [-s <username>] -j<jaildir> [-L <packageurl>] [-e <extras-path>]" >&2
+               echo "Usage: $0 [-l] [-p] [-c] [-m] [-M] [-f <filename>] -j<jaildir> [-L <packageurl>] [-e <extras-path>]" >&2
                exit 1
        ;;
        b)
@@ -99,8 +99,6 @@ do
        f)
                FILENAMEOUT="$OPTARG"
                ;;
-       s)      USERNAME="--username=$OPTARG"
-               ;;
        m)      MINIMAL=1
                PACKAGES=0
                ;;
@@ -194,10 +192,9 @@ else
        ( cd .. && make cleandir >/dev/null )
        echo "Copying contents from current src dir."
        srcdir=/usr/$SRC
-       ( cd $srcdir && tar --exclude .svn -cf - .  ) | ( cd $RELEASEDIR/usr && mkdir $SRC && cd $SRC && tar xf - )
+       ( cd $srcdir && tar --exclude .git -cf - .  ) | ( cd $RELEASEDIR/usr && mkdir $SRC && cd $SRC && tar xf - )
        echo "Copying done."
        REVTAG=copy
-       REVISION=unknown
        IMG=${IMG_BASE}_copy.iso
 fi
 
@@ -244,7 +241,7 @@ echo " * Removing bootstrap files"
 chown -R root $RELEASEDIR/usr/src*
 cp issue.install $RELEASEDIR/etc/issue
 
-echo $version_pretty, SVN revision $REVISION, generated `date` >$RELEASEDIR/etc/version
+echo $version_pretty, GIT revision $REVTAG, generated `date` >$RELEASEDIR/etc/version
 rm -rf $RELEASEDIR/tmp/*
 
 if [ $MINIMAL -ne 0 ]