Browse Source

Lets build.sh reject HEAD as BASE-identifier for non-experimental
builds.

As HEAD is a "floating" pointer, it cannot act as valid qualifier for
reproducible builds. One either has to specify a commit by its tag (if
existent) or the qualifying commit SHA.

Stefan Laudemann 9 years ago
parent
commit
d0addf5501
1 changed files with 6 additions and 0 deletions
  1. 6 0
      build.sh

+ 6 - 0
build.sh

@@ -35,6 +35,12 @@ if [ "_$BASE" == "_" ]; then
 	exit 1
 fi
 
+if [ "${BRANCH}" != "experimental" -a "${BASE}" == "HEAD" ] ; then
+	echo "HEAD is not an allowed BASE-identifier for non-experimental builds." >&2
+	echo "Either use a tagged commit or the commit-SHA itself." >&2
+	exit 1
+fi
+
 if [ "_$VERSION" == "_" -a "$BRANCH" != "experimental" ]; then
 	echo "Please specify VERSION environment variable (not necessary for experimental branch)." >&2
 	exit 1