From: Pieter Lexis Date: Mon, 24 Oct 2016 14:26:45 +0000 (+0200) Subject: Replace all non-alphanumeric chars in gen-version X-Git-Tag: dnsdist-1.1.0-beta2~68^2 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=refs%2Fpull%2F4613%2Fhead;p=thirdparty%2Fpdns.git Replace all non-alphanumeric chars in gen-version --- diff --git a/build-aux/gen-version b/build-aux/gen-version index 463403b2bd..a531f28cea 100755 --- a/build-aux/gen-version +++ b/build-aux/gen-version @@ -27,7 +27,7 @@ if [ ! -z "$(git rev-parse --abbrev-ref HEAD 2> /dev/null)" ]; then VERSION="$(git describe --match=${REL_TYPE}-* --dirty=.dirty | cut -d- -f 2-)" else GIT_VERSION=$(git show --no-patch --format=format:%h HEAD) - BRANCH=".$(git rev-parse --abbrev-ref HEAD | perl -p -e 's/-//g;')" + BRANCH=".$(git rev-parse --abbrev-ref HEAD | perl -p -e 's/[^[:alnum:]]//g;')" [ "${BRANCH}" = ".master" ] && BRANCH='' VERSION="0.0${BRANCH}.${PDNS_BUILD_NUMBER}g${GIT_VERSION}${DIRTY}" fi