diff options
-rwxr-xr-x | trunk/utils/simpletrack | 12 |
1 files changed, 5 insertions, 7 deletions
diff --git a/trunk/utils/simpletrack b/trunk/utils/simpletrack index d20f770..a0749e4 100755 --- a/trunk/utils/simpletrack +++ b/trunk/utils/simpletrack @@ -16,27 +16,24 @@ # Place - Suite 330, Boston, MA 02111-1307, USA # -PRIORITY="slacktrack-real altertrack slacktrack" +PRIORITY="slacktrack-real slacktrack altertrack" BASENAME="`basename $0`" function slacktrack { - # TODO: env vars $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.tgz" "./$2" } function slacktrack-real { - # TODO: env vars $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.tgz" "./$2" } function altertrack { - # TODO: command line argument and env vars - $1 ./$2 + $1 -b $REPOS -x $TMP,$SRC_DIR,/dev -jefkzp "$PACKAGE-$VERSION-$ARCH-$BUILD.tgz" "./$2" } @@ -47,16 +44,17 @@ function altertrack { if [ -z "$1" ]; then echo "usage: $BASENAME [options] <build-script>" exit 1 -else if [ ! -f "$1" ]; then +elif [ ! -f "$1" ]; then echo "$1: file not found" exit 1 fi for tracker in $PRIORITY; do - path=`which $tracker` + path="`which $tracker 2> /dev/null`" if [ "$?" == "0" ]; then echo $BASENAME: using $tracker... $tracker $path $* + break fi done |