Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 9 additions & 2 deletions .github/workflows/publish-nugets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ on:
jobs:
publish:
name: build, pack & publish
permissions:
id-token: write # enable GitHub OIDC token issuance for this job
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
Expand All @@ -23,6 +25,11 @@ jobs:
run: dotnet build --configuration Release --no-restore -p:Version=${{github.ref_name}}
- name: Pack
run: dotnet pack --configuration Release --no-build --no-restore -v normal -o ./nupkgs -p:Version=${{github.ref_name}}
- name: NuGet login (OIDC → temp API key)
uses: NuGet/login@v1
id: login
with:
user: ${{ secrets.NUGET_USER }}
- name: Push
run: dotnet nuget push *.nupkg -k ${{secrets.NUGET_API_KEY}} -s https://api.nuget.org/v3/index.json --skip-duplicate -n true
working-directory: ./nupkgs
run: dotnet nuget push *.nupkg --api-key ${{steps.login.outputs.NUGET_API_KEY}} --source https://api.nuget.org/v3/index.json --skip-duplicate -n true
working-directory: ./nupkgs
Loading