Publish Surge.NET package to GitHub Packages#184
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
Updates the release workflow to publish the Surge.NET NuGet package to the organization’s GitHub Packages feed during GitHub Releases, enabling package publication via the workflow GITHUB_TOKEN instead of nuget.org API keys.
Changes:
- Grants the release workflow token
packages: writepermission. - Replaces the NuGet.org push step with a
dotnet nuget pushto the GitHub Packages NuGet endpoint.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
15
to
+17
| permissions: | ||
| contents: write | ||
| packages: write |
| - name: Push to NuGet | ||
| run: dotnet nuget push ../nupkgs/*.nupkg --source nuget.org --api-key ${{ secrets.PETERSUNDE_NUGET_ORG_API_KEY }} --skip-duplicate | ||
| - name: Push to GitHub Packages | ||
| run: dotnet nuget push ../nupkgs/*.nupkg --source https://nuget.pkg.github.com/fintermobilityas/index.json --api-key ${{ secrets.GITHUB_TOKEN }} --skip-duplicate |
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Purpose
Publish the
Surge.NETNuGet package to the org GitHub Packages feed during releases.Why
The beta release pipeline can pack
Surge.NET, but nuget.org now rejects both configured org API-key secret paths with403. The downstream app repos already use the org NuGet feed for private packages, so publishing the beta package there gives the release workflow a repository-managed credential path viaGITHUB_TOKEN.Impact
packages: write..nupkgtohttps://nuget.pkg.github.com/fintermobilityas/index.json.Validation
git diff --checkdotnet pack dotnet/Surge.NET/Surge.NET.csproj --configuration Release -p:Version=1.0.0-beta.49 --output /tmp/surge-pack-checkMigration Notes
Downstream app repos that use package source mapping need
Surge.NETmapped to thefintermobilityassource before consuming the next beta.