From a93bfcfe86c6ead44cefeb049a164f05176ab2b0 Mon Sep 17 00:00:00 2001 From: Chris Frey Date: Tue, 17 Jul 2012 17:47:39 -0400 Subject: [PATCH] test: allow buildtest.sh to accept any branch on command line --- test/buildtest.sh | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/test/buildtest.sh b/test/buildtest.sh index 20df3bbb..4125115a 100755 --- a/test/buildtest.sh +++ b/test/buildtest.sh @@ -6,16 +6,15 @@ MAKEOPTS=-j2 export CC="ccache gcc" export CXX="ccache g++" -COMMIT=master # Make sure any errors stop the test set -e Usage() { - echo "Main Barry build test script. Tests the master branch." + echo "Main Barry build test script. Tests the master branch by default." echo echo "Usage:" - echo " ./buildtest.sh /path/to/libopensync-0.22.tar.bz2" + echo " ./buildtest.sh [commit] [/path/to/libopensync-0.22.tar.bz2]" echo echo "Or, write a ~/.barrytest2 file that contains shell commands" echo "setting OSYNCROOTDIR to the directory you used as a --prefix" @@ -91,7 +90,12 @@ if [ -d "build" ] ; then fi BASEPATH=$(pwd) -OSYNCSOURCE="$1" +COMMIT="$1" +OSYNCSOURCE="$2" + +if [ -z "$COMMIT" ] ; then + COMMIT="master" +fi mkdir -p build -- 2.11.4.GIT