Upgrade project dependencies and bump NuGet package version #25
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
push: | |
tags: | |
- "*" | |
jobs: | |
release-to-github: | |
name: Release to GitHub | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Build | |
id: build | |
run: | | |
dotnet restore --verbosity minimal | |
dotnet build --configuration Release --no-restore --verbosity minimal /p:ContinuousIntegrationBuild=true | |
dotnet pack --configuration Release --no-build --no-restore --verbosity minimal /p:ContinuousIntegrationBuild=true | |
nupkg_files=(artifacts/Release/*.nupkg) | |
echo "nupkg_name=$( basename ${nupkg_files[-1]} )" >> "${GITHUB_OUTPUT}" | |
echo "nupkg_path=${nupkg_files[-1]}" >> "${GITHUB_OUTPUT}" | |
snupkg_files=(artifacts/Release/*.snupkg) | |
echo "snupkg_name=$( basename ${snupkg_files[-1]} )" >> "${GITHUB_OUTPUT}" | |
echo "snupkg_path=${snupkg_files[-1]}" >> "${GITHUB_OUTPUT}" | |
- name: Create GitHub Release | |
id: create_github_release | |
uses: actions/create-release@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
tag_name: ${{ github.ref }} | |
release_name: ${{ github.ref }} | |
draft: true | |
prerelease: true | |
- name: Upload NuGet Package | |
uses: actions/upload-release-asset@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
asset_content_type: application/zip | |
asset_name: ${{ steps.build.outputs.nupkg_name }} | |
asset_path: ${{ steps.build.outputs.nupkg_path }} | |
upload_url: ${{ steps.create_github_release.outputs.upload_url }} | |
- name: Upload NuGet Symbol Package | |
uses: actions/upload-release-asset@master | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
asset_content_type: application/zip | |
asset_name: ${{ steps.build.outputs.snupkg_name }} | |
asset_path: ${{ steps.build.outputs.snupkg_path }} | |
upload_url: ${{ steps.create_github_release.outputs.upload_url }} |