diff --git a/cr.sh b/cr.sh index 609701d..8126548 100755 --- a/cr.sh +++ b/cr.sh @@ -256,6 +256,7 @@ lookup_latest_tag() { else # In a detached HEAD state, such as when the pipeline # is triggered by a push on a tag commit, we need to look back + # by date current_commit=$(git rev-parse HEAD) for tag in $(git tag --sort=-creatordate); do if [ $(git rev-parse "$tag") = "$current_commit" ]; then