From 3e702b034069114451c3d919b13aa8cb10cb2b8a Mon Sep 17 00:00:00 2001 From: richard Date: Thu, 19 Nov 2009 06:36:55 +0100 Subject: [PATCH] Updated build script to exit if tip revision and base revision is the same when building patches. --- build.sh | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) diff --git a/build.sh b/build.sh index 141f3a1..d8367af 100644 --- a/build.sh +++ b/build.sh @@ -2,8 +2,9 @@ RELEASEDIR=release BUILDDIR=build -VERSION=$(hg id -b)-$(hg id -n) -ZIPFILE=$VERSION.zip +VERSION=$(hg id -b) +REVISION=$(hg id -n) +ZIPFILE=$VERSION-$REVISION.zip PLUGINFILES="cstrike/*" DOCS="docs/*" @@ -35,7 +36,14 @@ then then MAKEPATCH=true PATCHREV="$2" - ZIPFILE=$VERSION-patch_$PATCHREV.zip + + if [ "$2" = $REVISION ] + then + echo "No changes since base revision." + exit 1 + fi + + ZIPFILE=$VERSION-patch-$REVISION-$PATCHREV.zip else echo "Missing base revision number. Usage: build.sh patch " exit 1