Conversation
Dynamically extract current version and update to major.minor.x format across expanded file types.
|
Contributor
There was a problem hiding this comment.
Pull request overview
Adds automation to derive the current GitVersion versionSpec from CI and uses it in repository-dispatch workflows that update versions across docs/workflows, while also switching those workflows to a shared auth+checkout action.
Changes:
- Add
extract-versionhelper to readversionSpecfrom.github/workflows/ci.yml. - Update
gitversion-publishedworkflow to compute aMajor.Minor.xtag and bulk-update references across repo files. - Update both version-bump workflows to use
gittools/cicd/auth-checkout@maininstead ofactions/checkout.
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated 4 comments.
| File | Description |
|---|---|
| utilities.ps1 | Adds extract-version for reading CI’s versionSpec. |
| .github/workflows/gitversion-published.yml | Switches checkout action; derives old/new tags and bulk-updates references before committing. |
| .github/workflows/examples-version.yml | Switches checkout action; improves logging around old/new tags before committing. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Comment on lines
+65
to
+68
| Write-Error "Could not find versionSpec in $filePath" | ||
| } | ||
| } else { | ||
| Write-Error "File not found: $filePath" |
| @@ -13,17 +13,32 @@ defaults: | |||
|
|
|||
| jobs: | |||
| update-gitversion-version: | |||
|
|
||
| $version = "${{ github.event.client_payload.newTag }}" | ||
|
|
||
| $oldTag = extract-version |
| permissions: | ||
| contents: write | ||
| if: ${{ github.event_name == 'repository_dispatch' }} | ||
| runs-on: ubuntu-24.04 |
Contributor
|
Thank you @arturcic for your contribution! |
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.



Integrate a service account for secure repository checkout in CI versioning workflows. Refine GitVersion update logic to extract existing versions and derive major.minor.x tags for improved accuracy.
Fixed #2001