Repository navigation
[2.x] Move releases to GitHub Actions and retire Azure Pipelines - #1518
Merged
Merged
Conversation
The Azure pipeline on release/2.x now fails on every PR (its VSTest task can't find Visual Studio on the current hosted image), and the GitHub Actions build added in #1415 already covers it. Releases still went out through publish.ps1 with an API key. - Delete azure-pipelines.yml and publish.ps1 (and their solution items), and swap the README's Azure badge for the GitHub Actions one. - Add .github/workflows/release.yml, adapted from main's: manual dispatch from release/2.x cuts <VersionPrefix>-preview.N (or a named milestone), a v2.* tag cuts the final release. Packages are pushed with NuGet trusted publishing. It has the same file name as main's so it appears in the Actions tab and shares the NuGet policy. The GitHub Release is created with --latest=false so NAudio 3 stays "Latest". - Centralise the lockstep version as <VersionPrefix> in Directory.Build.props (bumped to 2.4.1, the next patch) instead of a <Version> in each of the nine package projects. A <Version> overrides <VersionSuffix>, so previews couldn't be versioned otherwise. - Add Directory.Build.targets: package validation for the package projects against the 2.4.0 baseline, so a patch release can't drop public API, plus the target that loads the release notes file into PackageReleaseNotes. CompatibilitySuppressions.xml files record the two by-design Windows-only API differences between TFMs that 2.4.0 already shipped (Mp3FileReader in NAudio, AudioPlaybackEngine in NAudio.Extras). - Add ReleaseInstructions.md describing the 2.x release flow. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01FffhFbNE3FjRzf35ztiVkA
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.
Summary
Gives
release/2.xthe same CI and release flow asmain, so occasional 2.x fix drops can be published from GitHub Actions.azure-pipelines.yml(itsVSTest@2task now fails on every PR with "Visual Studio 2015 is not found" on the current hosted image) andpublish.ps1. Also removes their solution items and swaps the README's Azure badge for thebuild.ymlbadge on this branch. The GitHub Actionsbuildworkflow from [v2 branch] ci: add GitHub Actions build workflow #1415 already covers CI..github/workflows/release.yml, adapted frommain's:release/2.xcuts<VersionPrefix>-preview.<run_number>, or a named milestone such asrc.1.v2.*tag push cuts the final release. It checks the tag matchesVersionPrefixand thatRELEASE_NOTES.mdhas a matching section, then builds, tests, packs the nine packages (and checks the count) and pushes them via NuGet trusted publishing.main's, on purpose. GitHub only lists dispatchable workflows from the default branch but runs the copy from the branch you pick, so it shows up as "release" withrelease/2.xin the branch dropdown. Tag pushes run the file at the tagged commit, sov2.*tags run this one andv3.*tags runmain's. As far as I know the NuGet policy is keyed on the workflow file name, so the existing one should cover this file too.--latest=false, so a 2.x release doesn't displace NAudio 3 as the repo's "Latest".<VersionPrefix>2.4.1</VersionPrefix>inDirectory.Build.propsreplaces the<Version>2.4.0</Version>in each of the nine package projects. This is required, not just tidying: a<Version>overrides<VersionSuffix>, so previews couldn't be versioned otherwise. It's 2.4.1 because 2.4.0 has shipped and previews need to sort above it.Directory.Build.targets:PackageReleaseNotes(same asmain).CompatibilitySuppressions.xmlfiles record the only existing differences between TFMs, which are by-design Windows-only types that 2.4.0 already ships:Mp3FileReaderinNAudioandAudioPlaybackEngineinNAudio.Extras.ReleaseInstructions.mdfor the 2.x flow: previews, the pre-flight PR, the tag, the post-release bump.Release notes
### Unreleasedsection of RELEASE_NOTES.mdThe packages themselves don't change, apart from the version moving to 2.4.1.
Testing
Verified locally on Linux with the .NET 10 SDK and PowerShell 7:
BiQuadFilterinternal and the build failed withCP0001 ... exists on [Baseline] ... but not on ....pwsh. Dispatch gives2.4.1-preview.42,milestone=rc.1gives2.4.1-rc.1, av2.4.1tag gives a final, and av2.4.2tag fails with the mismatch error.### Unreleasedgives empty notes (guarded here;main's copy has a reversed-range edge case with an empty section). A missing### 2.4.1fails as it should, and the### 2.4.0section extracts correctly.VersionSuffix=preview.42and a notes file: the nuspec has<version>2.4.1-preview.42</version>, the release notes, and dependencies onNAudio.Core 2.4.1-preview.42.NAudioTestsstill builds.Can't be checked from a PR (not yet run):
release/2.xafter this merges.NAudio.Uap. It's the one packagemainnever pushes.Manual follow-ups (repo/Azure settings)
main). See "Retiring Azure DevOps" inDocs/Architecture/ReleaseStrategy.mdonmain.Generated by Claude Code