1
0
Fork 0
mirror of synced 2024-05-18 19:42:54 +12:00

Workflows: Fix tag sorting

This commit is contained in:
loathingKernel 2023-05-03 18:47:40 +03:00
parent e5a56cb0fb
commit 3a396d5982
No known key found for this signature in database
GPG key ID: CE0C72D0B53821FD

View file

@ -22,7 +22,7 @@ jobs:
id: version
shell: bash
run: |
tag_abbrev=$(git tag | sort -h | grep -oE "(^[0-9]+\.[0-9]+(.[0-9]+)?)$" | tail -1)
tag_abbrev=$(git tag --sort=v:refname | grep -oE "(^[0-9]+\.[0-9]+(.[0-9]+)?)$" | tail -1)
echo "tag_abbrev=$tag_abbrev" >> $GITHUB_OUTPUT
echo "tag_offset=$(git rev-list $tag_abbrev..HEAD --count)" >> $GITHUB_OUTPUT
echo "sha_short=$(git rev-parse --short HEAD)" >> $GITHUB_OUTPUT