From 780989f15c90ba3f6d9884cef659b5001c1f7bcc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jose=20Villase=C3=B1or=20Montfort?= <195970+montfort@users.noreply.github.com> Date: Thu, 11 Jun 2026 00:18:41 -0600 Subject: [PATCH] ci: verify .codex/skills stays in sync with .claude source Adds a CI workflow running `gen_codex_skills --check` on PRs (and pushes to main) that touch the Claude skill sources, the generated Codex tree, or the generator itself. Until now nothing enforced the regeneration step, so a hand-edit to .claude/skills/ without re-running the generator could ship a stale .codex/skills/ tree (the exact failure mode behind the #232 identity drift). Fix locally with `cd cli && cargo run --bin gen_codex_skills`. Co-Authored-By: Claude Opus 4.8 (1M context) --- .github/workflows/ci.yml | 43 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..7a933c9 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,43 @@ +name: CI + +on: + pull_request: + paths: + - 'dist/.claude/skills/**' + - 'dist/.codex/skills/**' + - 'cli/src/bin/gen_codex_skills.rs' + - '.github/workflows/ci.yml' + push: + branches: [main] + paths: + - 'dist/.claude/skills/**' + - 'dist/.codex/skills/**' + - 'cli/src/bin/gen_codex_skills.rs' + - '.github/workflows/ci.yml' + +permissions: + contents: read + +env: + CARGO_TERM_COLOR: always + +jobs: + codex-skills-sync: + name: Codex skills in sync with Claude source + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v6 + + - name: Install Rust toolchain + uses: dtolnay/rust-toolchain@stable + + - name: Install OpenSSL (Linux) + run: sudo apt-get update && sudo apt-get install -y libssl-dev pkg-config + + - name: Verify .codex/skills is regenerated from .claude/skills + working-directory: cli + run: | + # Fails if dist/.codex/skills/ drifted from what gen_codex_skills would + # produce from dist/.claude/skills/. Fix locally with: + # cd cli && cargo run --bin gen_codex_skills + cargo run --quiet --bin gen_codex_skills -- --check