Skip to content

v1.1.1

v1.1.1 #8

Workflow file for this run

name: Release
on:
release:
types:
- published
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get version
# Extract the version from the release tag.
run: |
TAG_NAME=$GITHUB_REF_NAME
VERSION=$(echo $TAG_NAME | sed -r 's/^v?([0-9.]+)$/\1/')
echo "Version=$VERSION" >> $GITHUB_ENV
- name: Setup .NET
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
8.0.x
9.0.x
- name: Install dependencies
run: dotnet restore
- name: Pack
run: dotnet pack -c Release --no-restore -o .
- name: Publish Nuget packages
run: dotnet nuget push *.nupkg -s https://api.nuget.org/v3/index.json --skip-duplicate -n -k ${{secrets.NUGET_API_KEY}}