RELEASE-CHECKLIST: Require version argument
authorIan Jackson <ijackson@chiark.greenend.org.uk>
Sat, 25 Oct 2014 21:04:22 +0000 (22:04 +0100)
committerIan Jackson <ijackson@chiark.greenend.org.uk>
Sun, 26 Oct 2014 11:45:58 +0000 (11:45 +0000)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
RELEASE-CHECKLIST

index af1cbc1..574fa1b 100755 (executable)
@@ -9,7 +9,7 @@
 #  * Update ADNS_VERSION_STRING in client/client.h
 #
 #  * Run this script
-#      ./RELEASE-CHECKLIST
+#      ./RELEASE-CHECKLIST <version>
 #
 #  * On chiark, maybe, replace ~ian/public-html/adns/current
 #    with symlink to web-$(version) (as directed by script)
 
 set -e
 
+fail () { echo >&2 "$0: $*"; exit 16; }
+
+if [ $# != 1 ]; then fail "wrong # arguments"; fi
+wantversion="$1"
+
 version=`sed -n <Makefile.in 's/^DISTVERSION=[ ]*//p'`
 
+if [ "x$version" != "x$wantversion" ]; then
+       fail "you say version $wantversion but tree is $version"
+fi
+
 gpgkey='-u 0x48B50D39'
 chiark=chiark:/u/ian/public-html/adns
 chiarkftp=$chiark/ftp