From 3ddce5fb90df4dac45d982ecd042f068ac7e907f Mon Sep 17 00:00:00 2001 From: bp-sawyers Date: Mon, 29 Jul 2013 15:36:37 +0000 Subject: [PATCH] Update bld script for different git branches git-svn-id: https://svn.code.sf.net/p/xcat/code/xcat-core/branches/2.8@17035 8638fb3e-16cb-4fca-ae20-7b5d299a9bcd --- buildcore.sh | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/buildcore.sh b/buildcore.sh index c374d91c4..0a2db354b 100755 --- a/buildcore.sh +++ b/buildcore.sh @@ -18,8 +18,8 @@ # - Run this script from the local svn repository you just created. It will create the other # directories that are needed. -# Usage: buildcore.sh BRANCH= [attr=value attr=value ...] -# BRANCH= - the branch within the git repo that should be built. This arg is required for git. +# Usage: buildcore.sh [attr=value attr=value ...] +# Before running buildcore.sh, you must change the local git repo to the branch you want built, using: git checkout # PROMOTE=1 - if the attribute "PROMOTE" is specified, means an official dot release. This does not # actually build xcat, just uploads the most recent snap build to https://sourceforge.net/projects/xcat/files/xcat/ . # If not specified, a snap build is assumed, which uploads to https://sourceforge.net/projects/xcat/files/yum/ @@ -70,10 +70,6 @@ if [ -z "$REL" ]; then D=${curdir%/src/xcat-core} REL=`basename $D` fi -if [ "$REL" = "xcat-core" -a -z "$BRANCH" ]; then # using git but they didnt specify BRANCH - echo "Error: must specify BRANCH= when building a git repository. Exiting...." - exit 1 -fi OSNAME=$(uname) if [ "$OSNAME" != "AIX" ]; then @@ -155,11 +151,10 @@ else #echo "source=$source" fi -# for the git case, set the current branch and also set REL (changing master to devel if necessary) +# for the git case, query the current branch and set REL (changing master to devel if necessary) function setbranch { - git checkout $BRANCH - #REL=`git rev-parse --abbrev-ref HEAD` - REL=$BRANCH + #git checkout $BRANCH + REL=`git rev-parse --abbrev-ref HEAD` if [ "$REL" = "master" ]; then REL="devel" fi