Use a shorter suffix for modified development versions.

The default --iso-preparer value will fit into 128 bytes for a git
checkout with local modifications (the longest version variant).
This commit is contained in:
Roland Clobus 2022-04-20 08:54:19 +02:00
parent 2a7bb73bf7
commit ba5c0c37d1
No known key found for this signature in database
GPG Key ID: 62C57C6AA61495BD
1 changed files with 2 additions and 2 deletions

View File

@ -19,10 +19,10 @@ VERSION=""
# 3) For installed versions, the version from the file VERSION # 3) For installed versions, the version from the file VERSION
if [ ! -z "${LIVE_BUILD}" -a "$(command -v git)" -a -e ${LIVE_BUILD}/.git ]; then if [ ! -z "${LIVE_BUILD}" -a "$(command -v git)" -a -e ${LIVE_BUILD}/.git ]; then
VERSION="$(cd ${LIVE_BUILD}; git log -n 1 --pretty=format:%H_%aI)" VERSION="$(cd ${LIVE_BUILD}; git log -n 1 --pretty=format:%H_%aI)"
# If a local modification is made or there are staged commits, add 'with_local_changes' # If a local modification is made or there are staged commits, add 'mod'
# See https://stackoverflow.com/questions/2657935/checking-for-a-dirty-index-or-untracked-files-with-git # See https://stackoverflow.com/questions/2657935/checking-for-a-dirty-index-or-untracked-files-with-git
if ! $(cd ${LIVE_BUILD}; git diff-index --quiet HEAD --ignore-submodules --); then if ! $(cd ${LIVE_BUILD}; git diff-index --quiet HEAD --ignore-submodules --); then
VERSION="${VERSION}_with_local_changes" VERSION="${VERSION}_mod"
fi fi
fi fi
if [ -z "${VERSION}" -a ! -z "${LIVE_BUILD}" -a -e ${LIVE_BUILD}/debian/changelog ]; then if [ -z "${VERSION}" -a ! -z "${LIVE_BUILD}" -a -e ${LIVE_BUILD}/debian/changelog ]; then