Skip to content

Commit b0f8782

Browse files
committed
Replace artifact upload step with NuGet package publishing in release workflow
1 parent cdcc46f commit b0f8782

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

.github/workflows/release.yaml

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,8 +19,9 @@ jobs:
1919
run: dotnet build --no-restore --configuration Release /p:Version=${{ github.ref_name }}
2020
- name: Pack
2121
run: dotnet pack --no-build --configuration Release --output ./artifacts /p:Version=${{ github.ref_name }}
22-
- name: Upload NuGet package artifacts
23-
uses: actions/upload-artifact@v4
24-
with:
25-
name: nuget-packages
26-
path: ./artifacts/*.nupkg
22+
- name: Publish
23+
shell: pwsh
24+
run: |
25+
Get-ChildItem -Path ./artifacts -Recurse | ForEach-Object {
26+
dotnet nuget push $_.FullName --api-key ${{ secrets.NUGET_API_KEY }} --source https://api.nuget.org/v3/index.json --skip-duplicate
27+
}

0 commit comments

Comments
 (0)