Skip to content

Stabilize CMake GitHub Actions by using pinned submodules and the correct test flag#33

Merged
yanyiwu merged 2 commits intomasterfrom
copilot/review-github-actions-configuration
Mar 23, 2026
Merged

Stabilize CMake GitHub Actions by using pinned submodules and the correct test flag#33
yanyiwu merged 2 commits intomasterfrom
copilot/review-github-actions-configuration

Conversation

Copy link
Copy Markdown
Contributor

Copilot AI commented Mar 13, 2026

The current GitHub Actions CMake workflow has room for improvement around reproducibility and correctness. It was overriding pinned submodule revisions at CI time and passing a CMake option the project does not use.

  • Use repository-pinned submodules

    • Switch checkout to submodules: recursive so nested dependencies are fetched directly by actions/checkout.
    • Remove the manual submodule update step that pulled cppjieba from remote master, which made CI depend on upstream head instead of the revision pinned in this repo.
  • Use the project’s actual CMake test toggle

    • Replace -DBUILD_TESTING=ON with -Dsimhash_BUILD_TESTS=ON to match the option defined in the top-level CMakeLists.txt.
  • Net effect

    • CI now builds against the exact submodule revisions tracked by the repository.
    • Test targets are enabled through the option the project actually consumes.
- uses: actions/checkout@v3
  with:
    submodules: recursive
    fetch-depth: 0

- name: Configure CMake
  run: cmake -B ${{github.workspace}}/build -Dsimhash_BUILD_TESTS=ON -DCMAKE_CXX_STANDARD=${{matrix.cpp_version}} -DCMAKE_BUILD_TYPE=${{matrix.build_type}}

💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

Co-authored-by: yanyiwu <2162645+yanyiwu@users.noreply.github.com>
Copilot AI changed the title [WIP] Review and improve GitHub Actions configuration Stabilize CMake GitHub Actions by using pinned submodules and the correct test flag Mar 13, 2026
Copilot AI requested a review from yanyiwu March 13, 2026 07:54
@yanyiwu yanyiwu marked this pull request as ready for review March 23, 2026 14:49
@yanyiwu yanyiwu merged commit 00d6208 into master Mar 23, 2026
@yanyiwu yanyiwu deleted the copilot/review-github-actions-configuration branch March 23, 2026 14:49
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.

2 participants