Publish Spz.NET #2
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: "Publish Spz.NET" | |
on: | |
workflow_dispatch: | |
release: | |
types: [published] | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- name: Setup .NET | |
uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: 9.0.x | |
- name: Set distdir | |
run: | | |
echo "distdir=${{ github.workspace }}/nuget" >> "$GITHUB_ENV" | |
- name: Build project | |
run: | | |
dotnet pack -c Release -o ${{ env.distdir }} ${{ github.workspace }}/Spz.NET/ | |
- name: Publish to NuGet | |
run: | | |
dotnet nuget push ${{ env.distdir }}/*.nupkg --api-key ${{ secrets.GITHUB_TOKEN }} --source "https://nuget.pkg.github.com/${{ github.repository_owner }}/index.json" |