Explain grant-mismatch asks with a prompt notice - #960
Merged
Merged
Conversation
Short -f takes no value: real git rejects -f=<value> and glued -f<val> the way it rejects --force=<value>, so the worktree policy treats them as force instead of letting the generic-flag skip swallow them. The grant-mismatch notice keeps the destination noun for add and names the worktree itself for remove.
Collaborator
Author
|
Audit: Approve, no code change requested. Grant-mismatch notices name the guard reason without changing match semantics: every covered-but-guarded case still asks and stays deniable, only the prompt gains the why, and treating --force= as force intent is the safe direction. File-for-later: the startsWith("--force=") prefix over-matches in principle, since any --force= (including empty or garbage values real git would reject with exit 129) is treated as force. Harmless today because ask is the safe direction, but worth a precise matcher if the flag grammar ever grows. |
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.
Summary
--force=<value>spellings count as force in the worktree policy, so the inline-value skip can no longer swallow force intentVerification
bun run typecheck,bun run build, and the fullbun run checksuite pass (7141 pass, 0 fail)--force=<value>ask and the--no-forcepass-throughFixes CL-6824