File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change @@ -3,11 +3,13 @@ name: Zstd Archive Release
33on :
44 push :
55 tags :
6- - ' v[0-9]+.[0-9]+.[0-9]+' # Matching tags like v1.1.0
6+ - ' v*.*.*' # match v1.2.3, v10.20.30, etc.
7+ workflow_dispatch : # allow manual runs
78
89jobs :
910 release :
1011 runs-on : ubuntu-latest
12+
1113 steps :
1214 - name : Checkout repository
1315 uses : actions/checkout@v4
@@ -18,13 +20,18 @@ jobs:
1820 - name : Extract version info
1921 id : version
2022 run : |
21- TAG_NAME="${GITHUB_REF#refs/tags/}"
23+ TAG_NAME="${GITHUB_REF#refs/tags/}" # e.g. v1.2.3
24+ SHORT_TAG="${TAG_NAME#v}" # strip leading "v" → 1.2.3
2225 echo "tag_name=$TAG_NAME" >> $GITHUB_OUTPUT
26+ echo "short_tag=$SHORT_TAG" >> $GITHUB_OUTPUT
2327
2428 - name : Create .tar.zst archives using git archive
2529 run : |
2630 git archive --format=tar --prefix=test-definitions/ ${{ steps.version.outputs.tag_name }} \
2731 | zstd -o ../${{ steps.version.outputs.tag_name }}.tar.zst
32+ git archive --format=tar --prefix=test-definitions/ ${{ steps.version.outputs.tag_name }} \
33+ | zstd -o ../${{ steps.version.outputs.short_tag }}.tar.zst
34+
2835 - name : Upload .tar.zst archives to GitHub Release
2936 uses : softprops/action-gh-release@v2
3037 with :
3542 ../${{ steps.version.outputs.short_tag }}.tar.zst
3643 env :
3744 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
45+
You can’t perform that action at this time.
0 commit comments