Pack RID-specific tool pointer packages with DotnetToolSettings.xml under tools/any/any#55107
Open
Copilot wants to merge 4 commits into
Open
Pack RID-specific tool pointer packages with DotnetToolSettings.xml under tools/any/any#55107Copilot wants to merge 4 commits into
Copilot wants to merge 4 commits into
Conversation
Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com>
Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Update pointer package to use any TFM for compatibility
Pack RID-specific tool pointer packages with DotnetToolSettings.xml under tools/any/any
Jul 1, 2026
baronfel
reviewed
Jul 1, 2026
Co-authored-by: baronfel <573979+baronfel@users.noreply.github.com>
Member
|
When we merge this we should backport to 10.0.4xx as well. |
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the RID-specific pointer tool package layout so that DotnetToolSettings.xml is emitted under tools/any/any/, keeping the pointer package TFM-agnostic while still referencing RID-specific implementation packages.
Changes:
- Adjust
Microsoft.NET.PackTool.targetsto place the pointer package’sDotnetToolSettings.xmlundertools/any/any/(while keeping implementation packages’ existing TFM/RID layout). - Extend end-to-end tool packaging assertions to validate the pointer package contains exactly one
DotnetToolSettings.xmland that it lives attools/any/any/DotnetToolSettings.xml.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| test/Microsoft.DotNet.PackageInstall.Tests/EndToEndToolTests.cs | Adds assertions to verify the pointer package has a single DotnetToolSettings.xml at tools/any/any/. |
| src/Tasks/Microsoft.NET.Build.Tasks/targets/Microsoft.NET.PackTool.targets | Updates packing logic to emit DotnetToolSettings.xml to a TFM-agnostic tools/any/any/ path for RID-specific pointer packages. |
dsplaisted
approved these changes
Jul 2, 2026
| static ZipArchiveEntry GetToolSettingsFileEntry(ZipArchive zipArchive) | ||
| { | ||
| var settingsEntries = zipArchive.Entries.Where(e => e.Name == "DotnetToolSettings.xml").ToArray(); | ||
| settingsEntries.Should().ContainSingle("tool packages should contain exactly one DotnetToolSettings.xml file"); |
Member
There was a problem hiding this comment.
I think multi-targeted tool packages can contain more than one tool settings file. But this is probably fine for the scenarios we're testing.
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.
RID-specific tool packaging currently places the top-level pointer package's
DotnetToolSettings.xmlunder a concrete TFM path. This change makes the pointer package emit the settings file undertools/any/anyso the package remains TFM-agnostic while still pointing to the RID-specific payload packages.Packaging layout
Microsoft.NET.PackTool.targetsso the top-level RID-specific pointer package writesDotnetToolSettings.xmltotools/any/any/.Pointer package behavior
anyTFM path only when packing the RID-specific top-level package that contains metadata but no implementation files.Coverage
DotnetToolSettings.xmland that its path istools/any/any/DotnetToolSettings.xml.anyRID payload.