Skip to content

Conversation

Copy link
Contributor

Copilot AI commented Feb 7, 2026

GitVersion 6.6.0 introduces two new output variables (VersionSourceSemVer, VersionSourceDistance) and deprecates CommitsSinceVersionSource (replaced by VersionSourceDistance, removal in v7.0.0).

Changes

  • src/tools/gitversion/models.ts — Added VersionSourceSemVer?: string and VersionSourceDistance?: number as optional fields on GitVersionOutput (optional since only present in ≥6.6.0; writeGitVersionToAgent iterates actual JSON keys so no runtime version gating needed)
  • gitversion/execute/action.yml — Declared new outputs versionSourceSemVer and versionSourceDistance; added deprecation notice to commitsSinceVersionSource
  • dist/azure/gitversion/execute/task.json — Added outputVariables array with all 26 output variables matching the GitHub action outputs, including the new variables and deprecation annotation
  • docs/examples/{github,azure}/gitversion/execute.md — Updated output lists with new variables and deprecation annotations
  • src/__tests__/tools/gitversion/runner.spec.ts — Updated createGitVersionFixture to include new fields in test data
Original prompt

This section details on the original issue you should resolve

<issue_title>[ISSUE]: New output variables added for GitVersion tool</issue_title>
<issue_description>I upcoming version of GitVersion 6.6.0 additional Output variables were added:

New variables:
VersionSourceSemVer
VersionSourceDistance

Obsolete variables
CommitsSinceVersionSource - obsolete and will be replaced by VersionSourceDistance; will be removed in v7.0.0

The docs will have to be updated with mentioning that new Variables added and the version number, and the deprecated variables.

The new variables should be included in the output only if the version of the installed tool (versionSpec) >= 6.6.x

The samples need to be updated where necessary. Unit tests should be updated if necessary.

DoD:

  • All unit tests are passing
  • code is formatted and linted
    </issue_description>

Comments on the Issue (you are @copilot in this section)


💡 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 in the docs.

…r GitVersion 6.6.0

Co-authored-by: arturcic <1760506+arturcic@users.noreply.github.com>
Copilot AI changed the title [WIP] Update output variables for GitVersion tool Add VersionSourceSemVer and VersionSourceDistance output variables for GitVersion 6.6.0 Feb 7, 2026
Copilot AI requested a review from arturcic February 7, 2026 21:17
…sion 6.6.0 variables

Co-authored-by: arturcic <1760506+arturcic@users.noreply.github.com>
@sonarqubecloud
Copy link

sonarqubecloud bot commented Feb 7, 2026

@arturcic arturcic marked this pull request as ready for review February 7, 2026 21:45
Copilot AI review requested due to automatic review settings February 7, 2026 21:45
Copy link

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

Adds support for new GitVersion 6.6.0 output variables across the TypeScript model, GitHub Action metadata, Azure Pipelines task metadata, docs, and test fixtures.

Changes:

  • Extend GitVersionOutput with optional VersionSourceSemVer and VersionSourceDistance.
  • Publish/document new outputs and mark commitsSinceVersionSource as deprecated (GitHub + Azure docs/metadata).
  • Update GitVersion runner test fixtures to include the new fields.

Reviewed changes

Copilot reviewed 5 out of 7 changed files in this pull request and generated no comments.

Show a summary per file
File Description
src/tools/gitversion/models.ts Adds optional fields for the new GitVersion 6.6.0 outputs.
src/tests/tools/gitversion/runner.spec.ts Extends extracted-output fixtures with the new fields.
gitversion/execute/action.yml Declares two new GitHub Action outputs and deprecation text for the old one.
dist/azure/gitversion/execute/task.json Adds an outputVariables allowlist including the new variables (and deprecation text).
docs/examples/github/gitversion/execute.md Documents new outputs and deprecation notice.
docs/examples/azure/gitversion/execute.md Documents new outputs and deprecation notice.
package-lock.json Lockfile metadata churn ("peer": true flags) unrelated to the feature.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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.

[ISSUE]: New output variables added for GitVersion tool

2 participants