Skip to content

Add multi-targeting example to CPM doc and improve wording #3440

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

jeffkl
Copy link
Contributor

@jeffkl jeffkl commented Jun 13, 2025

Users have asked for examples of how to reference different versions of packages for different target frameworks so this adds one.

I also took the time to clean up some of the wording and I asked Copilot to suggest improvements. You can look at just the first commit for the introduction of the multi-targeting example and the second commit is the cleanup

@Copilot Copilot AI review requested due to automatic review settings June 13, 2025 19:05
@jeffkl jeffkl requested review from a team as code owners June 13, 2025 19:05
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR adds a multi-targeting example to the Central Package Management documentation and refines the overall wording for improved clarity and consistency.

  • Adds an example demonstrating how to specify different package versions for multiple target frameworks using MSBuild conditions.
  • Updates headings, notes, and example code blocks to enhance readability and accuracy.
Comments suppressed due to low confidence (1)

docs/consume-packages/Central-Package-Management.md:102

  • [nitpick] Consider adding a brief inline comment or note in the code block to clarify that the logical OR condition applies the same version for both 'net8.0' and 'net472', which may help readers who are less familiar with MSBuild conditions.
<PackageVersion Include="PackageA" Version="2.0.0" Condition="'$(TargetFramework)' == 'net8.0' Or '$(TargetFramework)' == 'net472'" />

@NuGet NuGet deleted a comment from learn-build-service-prod bot Jun 13, 2025
Copy link

Learn Build status updates of commit 6f32e07:

✅ Validation status: passed

File Status Preview URL Details
docs/concepts/Auditing-Packages.md ✅Succeeded View
docs/consume-packages/Central-Package-Management.md ✅Succeeded View
docs/reference/errors-and-warnings/NU1011.md ✅Succeeded View

For more details, please refer to the build report.

Copy link
Member

@nkolev92 nkolev92 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great changes.
Some suggestions, but only 1 thing I actually feel like needs fixed (transitive pinning header)

@jeffkl jeffkl self-assigned this Jul 8, 2025
Copy link

PoliCheck Scan Report

The following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 issues. Other issues are also a high priority. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans.

✅ No issues found

More information about PoliCheck

Information: PoliCheck | Severity Guidance | Term
For any questions: Try searching the learn.microsoft.com contributor guides or post your question in the Learn support channel.

Copy link

Learn Build status updates of commit 09c2acf:

✅ Validation status: passed

File Status Preview URL Details
docs/consume-packages/Central-Package-Management.md ✅Succeeded View

For more details, please refer to the build report.

Copy link

PoliCheck Scan Report

The following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 issues. Other issues are also a high priority. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans.

✅ No issues found

More information about PoliCheck

Information: PoliCheck | Severity Guidance | Term
For any questions: Try searching the learn.microsoft.com contributor guides or post your question in the Learn support channel.

nkolev92
nkolev92 previously approved these changes Aug 14, 2025
Copy link
Member

@nkolev92 nkolev92 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You hadn't re-requested a review, but I'm guessing you're done making changes here.

This is looking much cleaner.

Copy link

PoliCheck Scan Report

The following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 issues. Other issues are also a high priority. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans.

✅ No issues found

More information about PoliCheck

Information: PoliCheck | Severity Guidance | Term
For any questions: Try searching the learn.microsoft.com contributor guides or post your question in the Learn support channel.

Copy link

Learn Build status updates of commit 916c0af:

✅ Validation status: passed

File Status Preview URL Details
docs/consume-packages/Central-Package-Management.md ✅Succeeded View

For more details, please refer to the build report.

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.

2 participants