Skip to content

Commit 8a81f70

Browse files
committed
nuget publish
1 parent c26f343 commit 8a81f70

1 file changed

Lines changed: 19 additions & 0 deletions

File tree

.github/workflows/dotnet.yml

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,3 +42,22 @@ jobs:
4242
with:
4343
name: nuget-package
4444
path: ./nupkgs/*.nupkg
45+
46+
deploy:
47+
runs-on: ubuntu-latest
48+
needs: build
49+
if: github.ref == 'refs/heads/main' && github.event_name != 'pull_request'
50+
environment: nuget-production
51+
52+
steps:
53+
- name: Download NuGet Package
54+
uses: actions/download-artifact@v4
55+
with:
56+
name: nuget-package
57+
path: ./nupkgs
58+
- name: Setup .NET
59+
uses: actions/setup-dotnet@v4
60+
with:
61+
dotnet-version: 8.0.x
62+
- name: Push to NuGet.org
63+
run: dotnet nuget push ./nupkgs/*.nupkg --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate

0 commit comments

Comments
 (0)