Skip to content

Commit 418a435

Browse files
committed
Strip leading v from release tag before passing as version
The release tag (e.g. v2026.1) was passed verbatim to generate_release_artifacts.py, which validates against YYYY.MICRO and rejected the v prefix. Derive a tag-less VERSION for the build action and artifact filenames; keep the original TAG only where it identifies the GitHub release itself.
1 parent 938d169 commit 418a435

1 file changed

Lines changed: 16 additions & 7 deletions

File tree

.github/workflows/release.yml

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,26 @@ jobs:
1717
with:
1818
ref: ${{ github.event.release.tag_name }}
1919

20+
- name: Derive version from release tag
21+
id: version
22+
run: echo "value=${TAG#v}" >> "$GITHUB_OUTPUT"
23+
env:
24+
TAG: ${{ github.event.release.tag_name }}
25+
2026
- uses: ./.github/actions/build-font
2127
with:
22-
version: ${{ github.event.release.tag_name }}
28+
version: ${{ steps.version.outputs.value }}
2329
push-image: 'true'
2430

2531
- name: Upload assets to the release
32+
env:
33+
TAG: ${{ github.event.release.tag_name }}
34+
VERSION: ${{ steps.version.outputs.value }}
2635
run: |
27-
gh release upload "${{ github.event.release.tag_name }}" \
28-
dist/xkcd-script-${{ github.event.release.tag_name }}.otf \
29-
dist/xkcd-script-${{ github.event.release.tag_name }}.ttf \
30-
dist/xkcd-script-${{ github.event.release.tag_name }}.woff \
31-
dist/xkcd-script-${{ github.event.release.tag_name }}.woff2 \
32-
dist/xkcd-mathjax3-${{ github.event.release.tag_name }}.js \
36+
gh release upload "$TAG" \
37+
"dist/xkcd-script-${VERSION}.otf" \
38+
"dist/xkcd-script-${VERSION}.ttf" \
39+
"dist/xkcd-script-${VERSION}.woff" \
40+
"dist/xkcd-script-${VERSION}.woff2" \
41+
"dist/xkcd-mathjax3-${VERSION}.js" \
3342
--clobber

0 commit comments

Comments
 (0)