Document v7 configuration layout and migration - #5160
Conversation
565e1f3 to
190a755
Compare
190a755 to
eb6cf46
Compare
eb6cf46 to
c0034ba
Compare
c0034ba to
e358ee3
Compare
e358ee3 to
c17e590
Compare
c17e590 to
0f91a29
Compare
0f91a29 to
6575eea
Compare
6575eea to
ae39600
Compare
ae39600 to
65c9d45
Compare
65c9d45 to
4215344
Compare
There was a problem hiding this comment.
🟡 Changes recommended
Some updated documentation YAML snippets contain duplicate keys in a single mapping, making the examples invalid YAML and potentially misleading.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Pull request overview
This PR updates GitVersion’s v7 documentation and published artifacts to reflect the nested configuration layout (calculation vs output) and the supported migration/override workflows, including regenerating the v7 configuration schema output.
Changes:
- Generate a nested-only v7 configuration schema (root contains only
calculationandoutput) while keeping prior versions’ schema output unchanged. - Update CLI/docs/migration guidance and examples to use version-aware nested override keys and document
gitversion config migrate. - Update breaking-changes documentation to describe the v7 configuration structure and migration path.
File summaries
| File | Description |
|---|---|
| src/GitVersion.Schema/Program.cs | Switches schema emission to a v7-specific writer for schema versions ≥ 7. |
| src/GitVersion.Schema/Extensions.cs | Adds v7 schema materialization that nests properties into calculation/output and filters branch properties appropriately. |
| schemas/7.0/GitVersion.configuration.json | Regenerated schema showing nested-only v7 layout and additionalProperties: false at the root. |
| docs/input/docs/usage/cli/assembly-patch.md | Updates --override-config example to the nested v7 key path. |
| docs/input/docs/usage/cli/arguments.md | Documents config migration and updates override-config examples to nested v7 keys (and v6 fallback notes). |
| docs/input/docs/reference/version-increments.md | Updates YAML examples to use the nested calculation section. |
| docs/input/docs/reference/mdsource/configuration.source.md | Adds v7 layout + migration + override guidance and updates multiple examples to nested structure. |
| docs/input/docs/reference/custom-formatting.md | Updates examples to place formatting settings under output and branch labels under calculation. |
| docs/input/docs/reference/configuration.md | Publishes the regenerated reference content describing the nested v7 layout and updated examples. |
| docs/input/docs/reference/build-servers/gitlab.md | Updates GitLab configuration example to nested v7 structure. |
| docs/input/docs/migration/v6-to-v7.md | Adds explicit v6→v7 configuration migration guidance, schema guidance, and environment variable notes. |
| docs/input/docs/learn/branching-strategies/githubflow/examples.md | Updates workflow example to nested calculation layout. |
| docs/input/docs/learn/branching-strategies/gitflow/examples.md | Updates workflow example to nested calculation layout. |
| BREAKING_CHANGES.md | Documents the v7 configuration structure and migration command/options. |
Review details
Suppressed comments (1)
docs/input/docs/reference/custom-formatting.md:202
- This YAML snippet also defines
assembly-informational-formattwice under the sameoutputmapping, which is invalid YAML and effectively drops the first example. Consider turning the second line into a commented alternative (or splitting into two separate example blocks).
output:
assembly-informational-format: "{Major}.{Minor}.{Patch}-{env:RELEASE_STAGE ?? 'dev'}"
assembly-informational-format: "{SemVer}+{env:BUILD_ID ?? 'local'}"
- Files reviewed: 14/14 changed files
- Comments generated: 1
- Review effort level: Lite
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
4215344 to
059456c
Compare
There was a problem hiding this comment.
🟢 Approval recommended
The schema generation logic and regenerated artifacts align with the documented v7 nested layout and the updates consistently propagate across the relevant documentation.
Review details
- Files reviewed: 14/14 changed files
- Comments generated: 0 new
- Review effort level: Lite
There was a problem hiding this comment.
🟡 Changes recommended
The monorepo ignore-path prose examples still imply leading-slash paths while the accompanying regex examples are repository-relative, which can mislead users.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
Suppressed comments (6)
docs/input/docs/reference/mdsource/configuration.source.md:436
- The bullet list describes paths with a leading
/, while the preceding regex examples match repository-relative paths without a leading slash. Using the same convention in the prose avoids suggesting users should include a leading/in their patterns.
A commit having changes only in `/ProjectB/*` path would be ignored. A commit having changes in the following paths wouldn't be ignored:
* `/ProjectA/*`
* `/LibraryC/*`
* `/ProjectA/*` and `/LibraryC/*`
docs/input/docs/reference/mdsource/configuration.source.md:439
- These combined-path examples also use leading slashes, which conflicts with the repository-relative regex examples above. Update them to be consistent with repository-relative paths.
* `/ProjectA/*` and `/ProjectB/*`
* `/LibraryC/*` and `/ProjectB/*`
* `/ProjectA/*` and `/ProjectB/*` and `/LibraryC/*`
docs/input/docs/reference/configuration.md:856
- These path examples include a leading
/, but the ignore-path regex patterns shown are repository-relative. Update the prose to use consistent repository-relative paths.
* Negative lookahead on anything other than `/ProjectA/*` and `/LibraryC/*`:
docs/input/docs/reference/configuration.md:869
- The prose/bullets describe paths with a leading
/, while the regex examples shown are repository-relative (no leading slash). Using one convention avoids suggesting users should prefix paths with/in their patterns.
A commit having changes only in `/ProjectB/*` path would be ignored. A commit having changes in the following paths wouldn't be ignored:
* `/ProjectA/*`
* `/LibraryC/*`
* `/ProjectA/*` and `/LibraryC/*`
docs/input/docs/reference/configuration.md:872
- These combined-path examples also use leading slashes, which conflicts with the repository-relative regex examples above. Update them to be consistent with repository-relative paths.
* `/ProjectA/*` and `/ProjectB/*`
* `/LibraryC/*` and `/ProjectB/*`
* `/ProjectA/*` and `/ProjectB/*` and `/LibraryC/*`
docs/input/docs/reference/mdsource/configuration.source.md:423
- These path examples include a leading
/, but the ignore-path regex patterns shown are repository-relative (no leading slash). Update the prose to use consistent repository-relative paths.
* Negative lookahead on anything other than `/ProjectA/*` and `/LibraryC/*`:
- Files reviewed: 11/11 changed files
- Comments generated: 2
- Review effort level: Lite
73b5188 to
fca8a10
Compare
There was a problem hiding this comment.
🟢 Approval recommended
The changes align documentation/examples with the v7 configuration model, with only a minor CLI docs grammar typo noted.
Review details
Suppressed comments (1)
docs/input/docs/usage/cli/arguments.md:145
- The sentence has a grammar error (“
valuehas be enclosed”), which reads like a typo and can confuse the CLI quoting guidance.
To have **space characters** as a part of `value`, `value` has be enclosed with double quotes - `key="My value"`.
- Files reviewed: 11/11 changed files
- Comments generated: 0 new
- Review effort level: Lite
fca8a10 to
9035dbd
Compare
There was a problem hiding this comment.
🟡 Changes recommended
The --override-config “supported override paths” section implies an exhaustive list but omits valid keys (e.g., output.pre-release-weight), which could mislead users.
Once you've addressed the issues Copilot identified, you can request another Copilot review.
Review details
- Files reviewed: 11/11 changed files
- Comments generated: 1
- Review effort level: Lite
|
@HHobeck, could you take another look at the stack? Following your feedback, I moved The implementation, migration command, schemas, and documentation now reflect this structure. CI and Sonar are green, and Copilot feedback has been addressed. |
9035dbd to
14a5142
Compare
14a5142 to
778098d
Compare
|
|
@Mergifyio queue |
Merge Queue Status
This pull request spent 2 minutes 21 seconds in the queue, including 5 seconds running CI. Required conditions to merge
|
|
Thank you @arturcic for your contribution! |



Summary
workflowselector alongsidecalculationandoutput.Validation
mdsnippets --write-header false.Closes #5134