Skip to content

chore(ci): publish to NuGet.org with Trusted Publishing - #26

Merged
Arthurvdv merged 2 commits into
masterfrom
chore/nuget-trusted-publishing
Nov 16, 2026
Merged

Arthurvdv merged 2 commits into
masterfrom
chore/nuget-trusted-publishing

Conversation

@Arthurvdv

Copy link
Copy Markdown
Member

Summary

The v1.6.0 release run failed at Publish to NuGet.org with NUGET_API_KEY not configured; the long-lived key is gone. This switches to Trusted Publishing, the same setup as ALCops/Analyzers:

  • build-and-release.yml: id-token: write in the workflow permissions, a NuGet/login@v1 step right before the push, and the push uses steps.nuget-login.outputs.NUGET_API_KEY.
  • CLAUDE.md: release convention note.

Setup before merging

  • nuget.org: Trusted Publishing policy, owner ALCops, repository ALCops/RoslynTestKit, workflow file build-and-release.yml (the Analyzers policy does not cover this repo; a policy matches one repository plus one workflow file)
  • GitHub: NUGET_USER secret available to this repository (nuget.org profile name, not email)

Release

v1.6.0 is tagged and on GitHub Packages but missing on NuGet.org. Squash-merge this with +semver: none in the commit body so GitVersion stays at 1.6.0 and the run publishes it.

🤖 Generated with Claude Code

Arthurvdv and others added 2 commits November 16, 2026 18:20
Replace the expired NUGET_API_KEY secret with NuGet/login, which
exchanges the job's GitHub OIDC token for a short-lived API key.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Arthurvdv
Arthurvdv merged commit 84a49ec into master Nov 16, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant