Skip to content

Commit

Permalink
Merge pull request #48 from vais-ral/tag_version
Browse files Browse the repository at this point in the history
update version tag logic
  • Loading branch information
gfardell authored Mar 9, 2022
2 parents 831e45d + 3d56297 commit da9cba4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions scripts/jenkins-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -51,8 +51,8 @@ if [[ -n ${CIL_VERSION} ]]
then
echo Using defined version: $CIL_VERSION
else
# define CIL_VERSION from last git tag, remove first char ('v') and leave rest
export CIL_VERSION=`git tag | xargs -I@ git log --format=format:"%at @%n" -1 @ | sort -V | awk '{print $2}' | tail -n 1 | tr -d '/s/v//g'`
# define CIL_VERSION from last git tag reachable from HEAD, remove first char ('v') and leave rest
export CIL_VERSION=`git tag --merged HEAD | xargs -I@ git log --format=format:"%at @%n" -1 @ | sort -V | awk '{print $2}' | tail -n 1 | tr -d '/s/v//g'`
fi

if [[ -z "${CIL_VERSION}" ]]
Expand Down

0 comments on commit da9cba4

Please sign in to comment.