Don't generate a Version Details Props header for repos with only SkipProperty dependencies#5209
Merged
dkurepa merged 2 commits intodotnet:mainfrom Aug 27, 2025
Merged
Conversation
SkipProperty dependencies
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR improves the Version Details Props file generation by skipping XML declaration generation for repositories that only contain dependencies with the SkipProperty flag set to true. The main change prevents unnecessary file headers from being generated when all dependencies in a repository are configured to skip property generation.
- Adds logic to skip repositories where all dependencies have
SkipProperty = true - Removes XML declaration (
<?xml version="1.0" encoding="utf-8"?>) from Version Details Props generation - Updates test expectations to reflect the removal of XML declarations
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
src/Microsoft.DotNet.Darc/DarcLib/Helpers/DependencyFileManager.cs |
Removes XML declaration generation and adds logic to skip repos with only skipped dependencies |
test/Microsoft.DotNet.DarcLib.Tests/Helpers/DependencyFileManagerTests.cs |
Updates test constants and expectations to remove XML declarations from expected output |
src/Microsoft.DotNet.Darc/DarcLib/Helpers/DependencyFileManager.cs
Outdated
Show resolved
Hide resolved
premun
previously approved these changes
Aug 27, 2025
…r.cs Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
premun
approved these changes
Aug 27, 2025
Merged
9 tasks
dkurepa
added a commit
that referenced
this pull request
Oct 8, 2025
…ty attribute changes (#5346) - [x] Review PR #5067 and #5209 changes to understand what was implemented - [x] Add section on Version.Details.props file - [x] Document the SkipProperty attribute in Version.Details.xml - [x] Document header generation behavior for repos with only SkipProperty dependencies - [x] Add examples showing proper configuration - [x] Update index and references throughout the document - [x] Build and test to ensure no syntax errors in documentation - [x] Address review feedback: Remove "When to use SkipProperty" section - [x] Address review feedback: Simplify migration steps <!-- START COPILOT CODING AGENT SUFFIX --> <details> <summary>Original prompt</summary> > > ---- > > *This section details on the original issue you should resolve* > > <issue_title>Update Darc.md documentation for Version.Details.props and SkipProperty attribute changes</issue_title> > <issue_description>Update the Darc.md documentation to reflect changes implemented in the following PRs: > - #5067 > - #5209 > > Key points to address: > > 1. **Version.Details.props File** > - Describe the addition of the new `Version.Details.props` file. > - Document that if `Version.Details.props` exists, it will be used. > - Explain when and how this file is generated or consumed. > > 2. **SkipProperty Attribute in Version.Details.xml** > - Introduce and document the `SkipProperty` attribute that can be added in `Version.Details.xml`. > - Describe its purpose and how it affects dependency management. > > 3. **Other Relevant Changes** > - Summarize any additional relevant changes from the referenced PRs, such as header generation behavior for repos with only `SkipProperty` dependencies. > > Ensure examples and configuration/process details are clear for users maintaining or integrating with Darc-managed repositories.</issue_description> > > ## Comments on the Issue (you are @copilot in this section) > > <comments> > </comments> > </details> Fixes #5345 <!-- START COPILOT CODING AGENT TIPS --> --- 💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more [Copilot coding agent tips](https://gh.io/copilot-coding-agent-tips) in the docs. --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: dkurepa <91743470+dkurepa@users.noreply.github.com> Co-authored-by: Přemek Vysoký <premek.vysoky@microsoft.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.
#5150
Also removes
<?xml version="1.0" encoding="utf-8"?>from VersionDetails.props, because it was not needed, since it's an msbuild file