Skip to content

Clear repeated Git config values completely - #4566

Merged
max-sixty merged 1 commit into
mainfrom
codex/config-clear-multivalues
Oct 22, 2026
Merged

max-sixty merged 1 commit into
mainfrom
codex/config-clear-multivalues

Conversation

@max-sixty

@max-sixty max-sixty commented Oct 22, 2026 •

Copy link
Copy Markdown
Owner

git config --unset returns status 5 both when a key is absent and when it has multiple values. Worktrunk treats that status as absence, so clearing repeated state values can report success while leaving the values on disk and removing them only from the in-memory cache.

Use --unset-all in the shared key-clearing helper. Status 5 then means absence, and a successful clear removes every value for the selected key. Add coverage for cached and fresh reads, repeated clears, and both named-variable and --all CLI paths.

Validation: all three regressions fail before the fix. All 171 focused state, repository-config, and commit-generation prompt tests pass with the fix.

The required cargo run -- hook pre-merge --yes gate passed in the combined audit checkout: 5,463 tests passed, one skipped, plus formatting, Clippy, lockfile checks, doctests, and rustdoc. The container runner supplied orphan reaping because its PID 1 does not reap children.

@max-sixty
max-sixty marked this pull request as ready for review October 22, 2026 23:48
@max-sixty
max-sixty merged commit 56c1b15 into main Oct 22, 2026
37 checks passed
@max-sixty
max-sixty deleted the codex/config-clear-multivalues branch October 22, 2026 23:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant