fix: restore per-platform RID so cross-compilation publish works#29
Merged
Conversation
…wn RID assets dotnet restore without -r only creates assets for net10.0 (no RID), so --no-restore on publish fails with NETSDK1047 when targeting win-x64 etc. Letting each dotnet publish handle its own restore fixes cross-compilation. dotnet pack --no-restore is fine — the initial restore covers net10.0 for packing. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
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.
Problem
release.ymlrandotnet restore(no-rflag), which only generates assets fornet10.0with no runtime identifier. Thendotnet publish --no-restoretried to use those assets fornet10.0/win-x64,net10.0/osx-arm64, etc. — which don't exist in the assets file, causing NETSDK1047.Fix
Remove
--no-restorefrom the publish loop. Eachdotnet publish -p:PublishProfile=<rid>now restores its own RID-specific assets before building. The initialdotnet restoreis kept for thedotnet pack(NuGet) step, which only needs the defaultnet10.0target and is unaffected.Merge order
Merge this before PR #28 (version bump to 1.2.3) so the fixed workflow is on main when the release triggers.
🤖 Generated with Claude Code