Skip to content
This repository was archived by the owner on Sep 11, 2023. It is now read-only.

Commit 6cbb2a5

Browse files
authored
Update betarelease.yml
1 parent 519796c commit 6cbb2a5

1 file changed

Lines changed: 10 additions & 3 deletions

File tree

.github/workflows/betarelease.yml

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,14 @@ jobs:
1818
uses: actions/checkout@v2
1919
with:
2020
fetch-depth: 0
21-
21+
22+
# Fetch latest tag and rev number
23+
- name: Get tag and rev number
24+
id: get-tag-rev
25+
run: |
26+
echo "::set-output name=TAG::$(git describe --match "[0-9].[0-9].[0-9].[0-9]" --tags --abbrev=0)"
27+
echo "::set-output name=REV::$(git rev-list HEAD --count)"
28+
2229
# Install the .NET Core workload
2330
- name: Install .NET Core
2431
uses: actions/setup-dotnet@v1
@@ -61,8 +68,8 @@ jobs:
6168
env:
6269
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
6370
with:
64-
tag_name: ${{ git describe --match "[0-9].[0-9].[0-9].[0-9]" --tags --abbrev=0 }}.beta${{ git rev-list HEAD --count }}
65-
release_name: Release ${{ git describe --match "[0-9].[0-9].[0-9].[0-9]" --tags --abbrev=0 }}.beta${{ git rev-list HEAD --count }}
71+
tag_name: ${{ steps.get-tag-rev.outputs.TAG }}.beta${{ steps.get-tag-rev.outputs.REV }}
72+
release_name: Release ${{ steps.get-tag-rev.outputs.TAG }}.beta${{ steps.get-tag-rev.outputs.REV }}
6673
draft: false
6774
prerelease: true
6875

0 commit comments

Comments
 (0)