Skip to content

Commit

Permalink
use only annotated tags to calculate git version
Browse files Browse the repository at this point in the history
  • Loading branch information
Yuvaraj Kakaraparthi committed Sep 20, 2021
1 parent b8ad4e4 commit e231731
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions hack/version.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ version::get_version_vars() {
fi

# stolen from k8s.io/hack/lib/version.sh
# Use git describe to find the version based on tags.
if GIT_VERSION=$(git describe --tags --abbrev=14 2>/dev/null); then
# Use git describe to find the version based on annotated tags.
if GIT_VERSION=$(git describe --abbrev=14 --match "v[0-9]*" 2>/dev/null); then
# This translates the "git describe" to an actual semver.org
# compatible semantic version that looks something like this:
# v1.1.0-alpha.0.6+84c76d1142ea4d
Expand Down

0 comments on commit e231731

Please sign in to comment.