Repository navigation
simplify: hand the Codex Cloud approvals to wt, at worktrunk 0.74.0 - #987
Merged
Merged
Conversation
`environment.sh` wrote the container's `approvals.toml` itself — project identifier, jq-rendered command list, heredoc, then a re-parse to confirm the schema still held. That existed only because `wt config approvals add` refused a non-TTY even with `--yes`; worktrunk 0.74.0 fixes that, so the command that owns the format does the job. Twenty-two lines become one, and a save it cannot make now fails the script rather than warning behind a `✓ saved`. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]>
tend-agent
approved these changes
Aug 14, 2026
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.
.config/codex-cloud/environment.shhand-wrote the container'sapprovals.toml: read the project identifier out ofwt config show --format json, render every command template throughjq, write the file with a heredoc, then parse it back to confirm the schema still held. It was a reimplementation ofwt config approvals add, and it existed for one reason — that command refused a non-TTY even when passed--yes, so there was no way to pre-approve a freshly cloned project unattended.worktrunk 0.74.0 fixes that (max-sixty/worktrunk#3819), so the whole block is now
wt config approvals add --yes. The schema re-parse goes with it:add --yesfails the command when it cannot save, rather than warning behind a✓ savedand exiting 0, which is exactly what that check was standing in for. The pin and the new line have to move together —--yesdoes nothing useful on 0.73.0.Testing against the released binary corrected a README claim.
add --yesmerges intoapprovals.tomlrather than truncating it, so an unrelated project's entry survives; the oldcat >genuinely replaced the file. "It replaces the container's Worktrunk approvals file" now reads as what actually makes the script Cloud-only — it approves this repo'swtcommands without review.The
WORKTRUNK_VERSIONrow inrunning-tendloses its instruction to check twojqpaths the script no longer uses.Verification
worktrunk-installer.sh, andwt --versionprints exactlywt v0.74.0— the string the script's install guard compares againstgit merge-base --is-ancestor 92dfb686b v0.74.0confirms the release carries the fix, rather than trusting the release notesXDG_CONFIG_HOME: the approval line exits 0 from tend's root, records all 8 commands.config/wt.tomldeclares, and leaveswt config approvals list --format=jsonatstate: approvedwith nothing staleTrue/False/Noneinside{{ vars.… }}) doesn't reach a.config/wt.tomlthat uses only{{ branch | hash_port }}and{{ args }}pre-commit run --all-filesclean;uv run pytest554 passed