Repository navigation
Conversation
Tested commit Verification Summary
Test details# Base quattro failure reproducing leaked temporary files:
$ bash test/shell.d/theme-set-settings-tmp-cleanup-test.sh
not ok - claude leaves no settings.json.XXXXXX litter when jq fails
# PR branch execution:
$ bash test/shell.d/theme-set-settings-tmp-cleanup-test.sh
ok - claude activate leaves no tmp litter and keeps settings.json on jq failure
ok - claude activate writes the theme on a valid settings.json
ok - pi activate leaves no tmp litter and keeps settings.json on jq failure
ok - pi activate writes the theme on a valid settings.json
$ bash test/shell.d/bin-style-test.sh
ok - bin commands use command helpers
ok - bin commands use the notification helper
$ git diff --check
$ bash -n bin/omarchy-theme-set-claude bin/omarchy-theme-set-pi test/shell.d/theme-set-settings-tmp-cleanup-test.sh
|
omarchy-theme-set-claude honours CLAUDE_CONFIG_DIR, so with it exported the test activated the theme in the real Claude settings rather than the scratch home. Pass it explicitly, as test/cli does. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Reviewed and run on a disposable Omarchy worker. The bug is real and the fix holds. Reproduction. With a Pushed 7e7ae7f. Tests. Second opinion. Codex Medium reviewed the diff and the test fix. It agreed the production change is correct and proportionate and that the Nothing is needed from the author. This waits on the maintainer, and on the unrelated |
[Low impact] The PR appears safe to merge; no actionable issues remain. SummaryClaude and Pi theme sync now remove staged files when settings updates, theme copies, or theme renames fail.
Reviews (3) · Last reviewed commit: "Merge quattro into theme-set-settings-tm..." · Reviewed by Greptile |
|
Re-reviewed at 080ce6b on a disposable Omarchy worker. The fix still holds, and the new failure cases test what they claim to. Reproduction. On current Suite. Second opinion. Codex Medium reviewed commit 080ce6b and the overlap below. It found no defect in the new cases: the stub matches only the intended Overlap with #13983. #13983 rewrites the same settings write in both scripts so that symlinked and permission-carrying Nothing is needed from the author now. This waits on the maintainer. |
Resolves the docs/testing.md conflict: quattro replaced the "Migrations run directly" convention with "Migrations get no suite test", so that bullet takes quattro's text and the staged-write bullet stays beside it. The scripts and the test merge cleanly. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
This pull request had stopped merging into Re-verified on a disposable Omarchy worker at ba7a4e0. Second opinion. Codex Medium and muse-wonder (via pi, thinking high) reviewed the merge and the diff against Fit with the test rules Overlap with #13983. That pull request is still open. It rewrites the same settings write in both scripts to keep settings symlinks and file metadata, and its EXIT trap already removes the staged settings file when jq or the rename fails. The two still conflict in both scripts. This pull request is the only one that cleans up a failed theme copy or rename. Both reviewers would land #13983's settings write and keep this pull request's theme-stage cleanup. If #13983 lands first, this one would shrink to the theme-stage cleanup and its test cases. Which goes first is the maintainer's call, so this one is labelled This waits on the maintainer. |
…r's pick
omarchy-theme-set-pi wrote the theme and the theme setting into ~/.pi/agent
even when PI_CODING_AGENT_DIR moves Pi's agent tree, so Pi never saw either.
Its Claude and Hermes siblings already follow their agent's variable.
- The agent directory is ${PI_CODING_AGENT_DIR:-~/.pi/agent}, with a leading
~ expanded the way Pi expands it (pi 1.5.0 getAgentDir()).
- --activate, which install/user/theme.sh runs on every re-provision, only
fills in an unset theme. A theme the user picked in Pi is kept.
- The settings write goes through a symlinked settings.json (dotfiles) to its
target, keeps the file's mode, and leaves the file untouched with no temp
litter when it is not valid JSON, reporting the failure.
test/shell.d/theme-set-pi-test.sh covers each case; it fails on the first
assertion against the previous script.
Fixes omacom#13691 (theme half). Supersedes omacom#13693, omacom#13718, omacom#13713 (Pi half) and
the Pi half of omacom#13983.
|
Closing this one, it's a minor edge case and not worth review time. Thanks to omarchybot for verifying it. |
What
omarchy-theme-set-claude/omarchy-theme-set-pistaged the newsettings.jsonthroughmktemp, then ran a barejq ... > tmp; mv tmp settings.jsonunderset -e. A hand-editedsettings.json(JSONC comments, trailing commas) makesjqfail: the script died leaving asettings.json.XXXXXXlitter file beside asettings.jsonit never updated.Fix
Guard both staged writes the way
theme-set-hermes'spublish_skinalready does: remove the temp file on failure, print a clear stderr message, exit nonzero. The settings file is never left half-written and no litter remains.Evidence
test/shell.d/theme-set-settings-tmp-cleanup-test.sh: fails on pristine base (litter assertion), 4/4 green on fix.bash -nandbin-style-test.shclean.Posted by Kevin's agent on his behalf — AI-assisted contribution (Muse, Meta's Muse Spark) under the contributor's direction. The contributor reviewed the change and takes responsibility for it.