Commit 82655e6a authored by Tails developers's avatar Tails developers
Browse files

Use more unique iso name when building from jenkins.

parent 570d4114
......@@ -71,10 +71,16 @@ export MKSQUASHFS_OPTIONS
# get git branch or tag so we can set the basename appropriately, i.e.:
# * if we build from a tag: tails-$ARCH-$TAG.iso
# * if we build from a branch: tails-$ARCH-$BRANCH-$VERSION-$DATE.iso
# * if jenkins build from a branch: tails-$ARCH-$BRANCH-$VERSION-$COMMIT-$TIME.iso
if GIT_REF="$(git symbolic-ref HEAD)"; then
GIT_BRANCH="${GIT_REF#refs/heads/}"
CLEAN_GIT_BRANCH=$(echo "$GIT_BRANCH" | sed 's,/,_,g')
BUILD_BASENAME="tails-${LB_ARCHITECTURE}-${CLEAN_GIT_BRANCH}-${AMNESIA_VERSION}-${AMNESIA_TODAY}"
if [ ! -z "$JENKINS_URL" ]; then
GIT_SHORT_ID="$(git rev-parse --short HEAD)"
BUILD_BASENAME="tails-${LB_ARCHITECTURE}-${CLEAN_GIT_BRANCH}-${AMNESIA_VERSION}-${GIT_SHORT_ID}-${AMNESIA_NOW}"
else
BUILD_BASENAME="tails-${LB_ARCHITECTURE}-${CLEAN_GIT_BRANCH}-${AMNESIA_VERSION}-${AMNESIA_TODAY}"
fi
else
GIT_CURRENT_COMMIT="$(git rev-parse HEAD)"
if GIT_TAG="$(git describe --tags --exact-match ${GIT_CURRENT_COMMIT})"; then
......
......@@ -24,6 +24,7 @@ if [ ! -x "`which dpkg-parsechangelog`" ]; then
fi
# Compute the current Amnesia's version once for all
AMNESIA_NOW="`TZ=UTC date '+%Y%m%dT%H%MZ'`"
AMNESIA_TODAY="`date '+%Y%m%d'`"
AMNESIA_VERSION="`dpkg-parsechangelog | sed -n 's/^Version: //p'`"
AMNESIA_FULL_VERSION="${AMNESIA_VERSION} - ${AMNESIA_TODAY}"
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment