docs(alias): correct the vars.* claim in alias dry-run - #3639
Merged
Conversation
The preview renderer now expands everything but the vars reference itself, so "templates referencing vars.* are shown unexpanded" no longer describes what alias dry-run does. The mention of a separate syntax validation step goes too — expansion reports those itself. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
worktrunk-bot
approved these changes
Jul 29, 2026
Merged
max-sixty
added a commit
that referenced
this pull request
Jul 29, 2026
) `wt hook show` decided whether a section had printed anything from whether the config held an entry for each hook type, not from whether any command was rendered. A hook type declared with an empty command list has an entry but no commands, so the section printed its heading and then stopped: ```console $ cat .config/wt.toml post-switch = [] $ wt hook show PROJECT HOOKS @ /path/.config/wt.toml ``` Both sections carried it, since the loop and the `(none configured)` fallback were duplicated in `render_user_hooks` and `render_project_hooks`. `render_hook_commands` now reports whether it wrote any rows, and the loop plus fallback live once in `render_hook_section`, which both callers delegate to. The flag means "something was printed", which is what the `(none configured)` line claims. The execution path was already correct: an empty list announces nothing, and the JSON output omits it. Verified against the built binary across four cases (project-only empty, user-only empty, an empty list alongside a real hook, and a filter naming the empty type), and pinned by `test_hook_show_empty_command_lists`, which covers both the user and project halves. Reverting the flag to its old meaning fails the test on both. Also corrects a docstring in the same file that still described the preview's pre-#3638 behavior ("shows a `vars.*` template raw"), the same drift #3639 fixed for `wt config alias dry-run`. > _This was written by Claude Code on behalf of max_ Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
max-sixty
added a commit
that referenced
this pull request
Jul 29, 2026
Two commits landed on `main` while #3640's CI ran, so they ship in 0.70.0 but weren't in its changelog. The release's drift check caught them before the tag. - **#3641** — a user-facing fix: `wt hook show` printed a section heading and nothing else for a hook type declared with an empty command list. Added as its own Fixed entry. - **#3639** — help-text only, no behavior change, correcting `wt config alias dry-run`'s description of the `vars.*` preview. Folded into the existing hook-previews bullet, since it's the same feature's documentation catching up rather than a separate change. No version change; `v0.70.0` is tagged after this lands so the tag covers both. > _This was written by Claude Code on behalf of Maximilian_
1 task
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.
#3638 changed the preview renderer so a template expands everything around a
{{ vars.<key> }}reference and leaves only that reference literal.wt config alias dry-runshares that renderer, but its--helptext and thehandle_alias_dry_rundocstring still described the previous all-or-nothing behavior, where a singlevars.token left the whole template raw.This corrects both. The docstring's mention of a separate syntax-validation step goes with them: expansion reports syntax errors itself, so there is no longer a distinct validation pass to describe.
No behavior change. The
dry-runlong help isn't rendered into any generated doc or snapshot, so no mirrors move with it.