Skip to content

Commit 1a07ebb

Browse files
committed
ci: keep pinned-config swap invisible to git in merge-queue job
The cp on its own left .mdsmith.yml dirty in the runner's checkout; merge-queue-action performs local checkout/merge operations after the merge driver is installed, and git would either refuse those with "local changes would be overwritten" or silently restore the new-shape config mid-merge — at which point the pinned binary stops being able to parse it. `git update-index --skip-worktree .mdsmith.yml` after the cp tells git to treat the file as unchanged. `git status` reports the worktree clean, branch switches and patch applies leave the swapped content alone, and the merge driver continues to see the pre-156 shape for the whole job lifetime. https://claude.ai/code/session_012GGH62fZUzLuzP8T4ocGkJ
1 parent 54b5569 commit 1a07ebb

1 file changed

Lines changed: 11 additions & 4 deletions

File tree

.github/workflows/merge-queue.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,18 @@ jobs:
4242
# merge) does the same. v0.15.0 cannot parse plan 156's
4343
# inline schema vocabulary, so the workflow swaps in
4444
# .mdsmith.pinned.yml — a config restated in the pre-156
45-
# shape — before the install / merge steps run. Remove this
46-
# swap once setup-mdsmith-pinned-version advances past
47-
# v0.15.0 (and delete .mdsmith.pinned.yml).
45+
# shape — for the entire job lifetime. `update-index
46+
# --skip-worktree` keeps the swap invisible to git so the
47+
# later checkout/merge operations performed by
48+
# merge-queue-action don't trip "local changes would be
49+
# overwritten" or try to restore the new-shape config
50+
# mid-merge. Remove this block once
51+
# setup-mdsmith-pinned-version advances past v0.15.0 (and
52+
# delete .mdsmith.pinned.yml).
4853
- name: Use pinned-binary config for merge driver
49-
run: cp .mdsmith.pinned.yml .mdsmith.yml
54+
run: |
55+
cp .mdsmith.pinned.yml .mdsmith.yml
56+
git update-index --skip-worktree .mdsmith.yml
5057
- name: Install mdsmith merge driver and pre-merge-commit hook
5158
run: |
5259
mdsmith merge-driver install

0 commit comments

Comments
 (0)