Skip to content

ci: Add release tag and version consistency verification workflow - #441

Open
DichenZhang1 wants to merge 1 commit into
mainfrom
ci/verify-release-tags
Open

ci: Add release tag and version consistency verification workflow#441
DichenZhang1 wants to merge 1 commit into
mainfrom
ci/verify-release-tags

Conversation

@DichenZhang1

Copy link
Copy Markdown
Collaborator

Summary

This PR adds an automated version consistency check workflow to validate that version strings remain aligned across CMakeLists.txt, ultrahdr_api.h, and Git release tags.

Key Features

  1. scripts/verify_tag_and_version.py:

    • Parses UHDR_MAJOR_VERSION, UHDR_MINOR_VERSION, UHDR_PATCH_VERSION from CMakeLists.txt.
    • Parses UHDR_LIB_VER_MAJOR, UHDR_LIB_VER_MINOR, UHDR_LIB_VER_PATCH from ultrahdr_api.h.
    • Validates that both in-tree version strings match.
    • When given --tag <tag_name> (e.g. v2.0.1), verifies that the tag matches the repository version.
  2. .github/workflows/verify_release_tag.yml:

    • Runs automatically on tag pushes (v*) to reject mismatched tags.
    • Runs on pull requests modifying CMakeLists.txt or ultrahdr_api.h to prevent committing mismatched version bumps.

- Add scripts/verify_tag_and_version.py to cross-validate version definitions
  across CMakeLists.txt, ultrahdr_api.h, and Git release tags.
- Add .github/workflows/verify_release_tag.yml to automatically run on tag
  pushes, main merges, and PRs touching version files.
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.

1 participant