Skip to content

Commit b46de50

Browse files
committed
ci: use trusted publishing
1 parent 1a336c4 commit b46de50

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

.github/workflows/release.yml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,10 +25,16 @@ jobs:
2525
run: dotnet test --configuration Release /p:Version=${VERSION} --no-build
2626
- name: Pack
2727
run: dotnet pack --configuration Release /p:Version=${VERSION} --no-build --output .
28+
29+
- name: NuGet login (OIDC → temp API key)
30+
uses: NuGet/login@v1
31+
id: login
32+
with:
33+
user: ascott18
34+
2835
- name: Push
29-
run: dotnet nuget push *.nupkg --source https://api.nuget.org/v3/index.json --api-key ${NUGET_KEY}
30-
env:
31-
NUGET_KEY: ${{ secrets.NUGET_KEY }}
36+
run: dotnet nuget push *.nupkg --source https://api.nuget.org/v3/index.json --api-key ${{ steps.login.outputs.NUGET_API_KEY }}
37+
3238
- name: Create GH Release
3339
uses: softprops/action-gh-release@v1
3440
with:

0 commit comments

Comments
 (0)