feat(cli): cli-3.44.0 — install-merge-driver, and correct what skipping it costs - #414
Merged
Conversation
…ng it costs Closes FU-001. The registry merge driver shipped in cli-3.41.0 to close #391, but taking effect needs two per-clone edits, and checking before building found the fix inert in every installation — Sentinel (296 entries, the adopter that filed #391), LNXDrive, and this repo. That reframed the ask. FU-001 proposed an `init` prompt, but `init` cannot run on an existing installation, so a flag alone would have helped nobody who already adopted. Hence a standalone command as well: - `straymark followups install-merge-driver [--path .]` — writes both halves, idempotently. An existing binding or a differently-configured driver is left untouched and reported; overwriting a deliberate override silently is not ours to do. - `straymark init --merge-driver` / `--no-merge-driver`, plus a prompt when neither is given. Gated on stdin being a TTY: init runs in CI and provisioning scripts, where a blocking prompt is a hang. Mirrors --hooks. Verifying it corrected something I had written into the code an hour earlier. I claimed that without the git-config half the .gitattributes line is "inert" and git "silently falls back to a normal conflict". Both wrong. An A/B merge on a seeded registry — same two branches, driver set in one clone and unset in the other — gives a clean merge with all closures intact in the first, and fatal: custom merge driver straymark-followups lacks command line in the second. The committable half BREAKS merges for anyone who has not run the setup. Corrected in the module doc, the generated .gitattributes comment, the command output and CLI-REFERENCE (en/es/zh-CN) — and it strengthens the case FU-001 made, since forgetting the step is a hard stop rather than friction. Dogfooded here, with the required clone step added to CONTRIBUTING.md, because committing the binding means contributors hit that fatal until they run it. Recorded honestly in AILOG-2026-08-06-001 R2: the premise behind FU-001 ("manual setup causes friction") was never verified — the driver was 16 hours old and non-adoption proved nothing. Built on the operator's call over a stated recommendation to dogfood first. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes FU-001.
What the premise check found
The registry merge driver shipped in
cli-3.41.0to close #391 — reported from Sentinel with concrete evidence: three closures silently reverted while merging three parallel PRs of one Charter.Before building, I checked whether the fix was in use. It was inert everywhere:
.gitattributesgit configThe global CLI was already 3.41.0, so the driver was available in all three.
Stated up front and unchanged by this PR: that is not evidence of setup friction — the driver was ~16 hours old, and 16 hours of non-adoption proves nothing. The build proceeded on your call, and
AILOG-2026-08-06-001R2 records it that way rather than retro-justifying it.What the data did support was a different framing: the fix was not reaching the adopter who asked for it, because a two-command step had not been run. That is what made a standalone command necessary — FU-001 proposed an
initprompt, butinitrefuses to run on an existing installation, so a flag alone would have helped nobody who has already adopted.Changes
straymark followups install-merge-driver [--path .]— writes both halves, idempotently. An existing binding (even to a different driver) and amerge.straymark-followups.driverpointing elsewhere are left untouched and reported: silently overwriting a deliberate override is not the tool's call.straymark init --merge-driver/--no-merge-driver, plus a prompt when neither is given — gated onstdin.is_terminal()and on the target being a git repo.initruns in CI and provisioning scripts, where a blocking prompt is a hang. Mirrors the--hooksprecedent (principle fix: consistent fw-/cli- version display across all commands #6).CONTRIBUTING.md.A correction to my own work
I had written — in the module doc and in the
.gitattributesblock the command generates — that without the git-config half the attribute line is "inert" and git "silently falls back to a normal conflict".Both are wrong. An A/B merge on a seeded registry (same two branches with diverging counters, driver configured in one clone and unset in the other):
fatal: custom merge driver straymark-followups lacks command line— merge abortsThe committable half does not just fail to help; it breaks merges for anyone who has not run the setup. Corrected in the module doc, the generated
.gitattributescomment, the command output, and CLI-REFERENCE (EN/es/zh-CN). It also sharpens FU-001's case: forgetting the step is a hard stop, not friction.Verified
cargo test: 958 passed, 0 failed.initprompt can be accepted more than once); an existing.gitattributessurvives including its last line when the file has no trailing newline; a foreign driver is preserved and reported; refuses outside a git repo;initexposes both flags.Known consequence
Committing
.gitattributeshere means a contributor who merges a branch touching the registry hits thatfataluntil they run the command. Mitigated where they will look — a numbered step inCONTRIBUTING.md§ Setup Steps, and the failure mode spelled out inside.gitattributesitself. The alternative, not committing the binding, means the driver never works for anyone, which is the state this PR exists to leave.Left open: wiring Sentinel and LNXDrive. Sentinel is the adopter that filed #391 and the only installation with the registry volume to hit the conflict routinely — until then the fix stays unexercised where it was needed. Recorded as a follow-up.
🤖 Generated with Claude Code