Skip to content

Commit

Permalink
alternative tag extraction using battila action
Browse files Browse the repository at this point in the history
  • Loading branch information
vinnie-fialok committed Jul 3, 2024
1 parent 475b8ad commit c990435
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,15 +16,11 @@ jobs:
name: Build - Release

runs-on: ubuntu-latest

steps:
- name: Extract tag name
id: tag_name
uses: actions/[email protected]
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
result-encoding: string
script: |
return context.payload.ref.replace(/^refs\/tags\//, '');
- name: Extract Version
id: version
uses: battila/get-version-action@v2

- name: Checkout
uses: actions/checkout@v3
Expand All @@ -43,7 +39,7 @@ jobs:
run: dotnet build --configuration Release

- name: Create NuGet Packages
run: dotnet pack --configuration Release /p:CommitID=${{ github.sha }} /p:TagVersion=${{ steps.tag_name.outputs.result }}
run: dotnet pack --configuration Release /p:CommitID=${{ github.sha }} /p:TagVersion=${{ steps.version.outputs.version-without-v }}

# Upload package as an atrifact to the GitHub action
- name: Upload packages
Expand Down

0 comments on commit c990435

Please sign in to comment.