You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[bug] sync-project.sh exits 1 silently before the bin/ and tests/e2e refresh when CLAUDE.md cites a Baseline skill without the Integration heading #227
What broke: bin/sync-project.sh exits 1 with no message partway through section 3 (the CLAUDE.md duplicate-routing check), so every step after it never runs: the crash-net bin/ refresh (#224), the tests/e2e/ install, and the lint-rule restore.
The script runs under set -euo pipefail. The check does:
_dup_from_line="$(grep -n 'mxcli-project-toolkit Integration'"$PROJECT_DIR/CLAUDE.md"| head -1 | cut -d: -f1)"
When CLAUDE.md cites skills/learned-mdl-preflight.md or skills/query-the-model.md but has no "mxcli-project-toolkit Integration" heading, grep exits 1. Pipefail makes that the pipeline's status, the assignment fails, and errexit ends the script. Every CLAUDE.md that mxcli init v0.25 writes has this shape.
Introduced by 9a0350b (2026-09-18, "stop CLAUDE.md/CLAUDE.local.md Baseline routing duplication"). Every sync since then has died here in the affected projects.
Command / script run (exact invocation): bin/sync-project.sh <project> --dry-run (the same happens without --dry-run)
Expected vs. actual:
Expected: the duplicate-routing warning, then the bin/ and tests/e2e/ steps, then the summary line, exit 0.
Actual: the last line printed is Would rewrite: CLAUDE.md Communication Style ..., then exit 1. There is no warning and no summary. bash -x shows the trace ending at + _dup_from_line=.
Field evidence:
Three consuming projects (TramiusECI, TramiusSCR, TramiusSVC), toolkit 69b223c, 2026-10-07.
With || true added inside the substitution, the dry run exits 0. It then lists 7 (SVC) and 8 (ECI) Would refresh: bin/... lines that had been skipped silently before.
The real run applied exactly those files (per-file hash diff before and after).
Reproduced on a fresh scaffold from the toolkit's own init-project.sh: append Read skills/query-the-model.md first. to CLAUDE.md, delete bin/exec.sh, and run a dry-run sync. It exits 1 and never prints Would install: bin/exec.sh.
Golden input: not a parser bug. The fixture builds the CLAUDE.md shape with the real init-project.sh.
Activity
MendixMau commentedon Oct 8, 2026
Fix and regression fixture in #231.
MendixMau commentedon Oct 13, 2026
Fixed by #231 (9dd9be4): the grep no longer stops sync-project.sh; covered by test-sync-dup-heading-exit.sh.
Closed after the 2026-10-13 triage, with the maintainer's go.
Generated by Claude Code