Skip to content

Commit

Permalink
actions: Fix next tag determination in release workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
PixelyIon committed Aug 2, 2024
1 parent 9dca02b commit f1eabbd
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -119,6 +119,9 @@ jobs:
contents: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all tags and history
filter: tree:0

- name: Download Windows build artifacts
uses: actions/download-artifact@v4
Expand All @@ -139,7 +142,7 @@ jobs:

- name: Determine Next Tag
run: |
latest_tag=$(git tag --sort=-creatordate --contains v | head -n 1); \
latest_tag=$(git tag --sort=-creatordate | grep -E '^v[0-9]+$' | head -n 1); \
if [ -z "$latest_tag" ]; then \
version=1; \
else \
Expand All @@ -162,7 +165,7 @@ jobs:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: v${{ env.VERSION }}
release_name: "Release ${{ env.VERSION }}"
release_name: "Release v${{ env.VERSION }}"
body: |
Automatic release of DeckTX for ${{ github.sha }}.
draft: false
Expand Down

0 comments on commit f1eabbd

Please sign in to comment.