Skip to content

feat: support GIT_TAG with CMake variable#149

Merged
vaind merged 2 commits intomainfrom
feat/cmake-variable-git-tag
Feb 18, 2026
Merged

feat: support GIT_TAG with CMake variable#149
vaind merged 2 commits intomainfrom
feat/cmake-variable-git-tag

Conversation

@jpnurmi
Copy link
Collaborator

@jpnurmi jpnurmi commented Feb 18, 2026

Summary

  • Extends Update-CMakeFile to handle GIT_TAG ${VAR} references where the actual value is defined in a set() call
  • Parse-CMakeFetchContent now resolves CMake variable references to their actual values
  • When updating, the set() line is modified instead of the GIT_TAG line, preserving the variable indirection
  • Supports both quoted and unquoted values, hash-to-hash updates with trailing # version comments

See also

Test plan

  • Added parse tests: quoted variable, unquoted hash variable, missing variable (error), direct value (null variable)
  • Added update tests: tag-to-tag via variable, file structure preservation, hash update via variable
  • All 23 tests pass (Invoke-Pester updater/tests/update-dependency-cmake.Tests.ps1)

When GIT_TAG uses a variable like ${FOO_REF}, resolve it to the
corresponding set() definition and update that line instead of the
FetchContent_Declare block.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@github-actions
Copy link
Contributor

github-actions bot commented Feb 18, 2026

Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.
📖 ✅ Custom dangerfile check: PR has a description
📖 ✅ Custom dangerfile check: PR title length is reasonable
📖 📊 Custom check: This PR changes 3 file(s)

Generated by 🚫 dangerJS against a2bbf00

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@vaind vaind merged commit 013cb4f into main Feb 18, 2026
20 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants

Comments