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

Commit 2d280a5

Browse files
authored
Update release.yml
1 parent 6cbb2a5 commit 2d280a5

File tree

1 file changed

+8
-16
lines changed

1 file changed

+8
-16
lines changed

.github/workflows/release.yml

Lines changed: 8 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -7,30 +7,22 @@ on:
77

88
jobs:
99

10-
# Get the latest tag
11-
get-tag:
12-
runs-on: ubuntu-latest
13-
outputs:
14-
tag: ${{ steps.previoustag.outputs.tag }}
15-
steps:
16-
- uses: actions/[email protected]
17-
with:
18-
fetch-depth: 0
19-
- name: Get previous tag
20-
id: previoustag
21-
uses: "WyriHaximus/github-action-get-previous-tag@v1"
22-
2310
# Build and release
2411
build:
2512

2613
runs-on: windows-latest
27-
needs: get-tag
2814
steps:
2915

3016
# Checkout the repository
3117
- name: Checkout
3218
uses: actions/checkout@v2
3319

20+
# Fetch latest tag
21+
- name: Get tag
22+
id: get-tag
23+
run: |
24+
echo "::set-output name=TAG::$(git describe --match "[0-9].[0-9].[0-9].[0-9]" --tags --abbrev=0)"
25+
3426
# Install the .NET Core workload
3527
- name: Install .NET Core
3628
uses: actions/setup-dotnet@v1
@@ -73,8 +65,8 @@ jobs:
7365
env:
7466
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
7567
with:
76-
tag_name: ${{ needs.get-tag.outputs.tag }}
77-
release_name: Release ${{ needs.get-tag.outputs.tag }}
68+
tag_name: ${{ steps.get-tag.outputs.TAG }}
69+
release_name: Release ${{ steps.get-tag.outputs.TAG }}
7870
draft: false
7971
prerelease: false
8072

0 commit comments

Comments
 (0)