Skip to content

provision: report installed tool versions per module#9

Merged
samialdury merged 1 commit into
mainfrom
show-versions
Jul 26, 2026
Merged

provision: report installed tool versions per module#9
samialdury merged 1 commit into
mainfrom
show-versions

Conversation

@samialdury

Copy link
Copy Markdown
Owner

Each module now ends by running what it installed through show_versions(), which prints cmd: <version> (<resolved path>) or warns when the command is not on PATH. An installed-but-unreachable binary should fail loudly rather than look like a successful install.

The version flag is not universal, so it tries --version, -V, -v and takes the first clean exit (tmux needs -V, dig needs -v). tailscale is done by hand — its CLI has only a version subcommand, no flag.

lib.sh also prepends ~/.local/bin to PATH at source time, so a module sees what an earlier one installed (claude, the bat/fd wrappers) without waiting for a new login shell; run-all.sh runs modules as children, which inherit it. That lets claude.sh drop its off-PATH warning and resolve claude by name, which doubles as the reachability check.

link_wrapper's destination check moves ahead of the has_cmd skip: with ~/.local/bin now on PATH, our own wrapper satisfies has_cmd bat, and the old order would silently skip instead of reporting.

provision/test/inside.sh covers all of it — every tool reports a version, none report ?, and the claude off-PATH case now asserts lib.sh repaired PATH instead of warning. Locally only ./scripts/test-install.sh ran (green); the container suite is left to CI.

🤖 Generated with Claude Code

Each module now ends by running what it installed through show_versions(),
which prints "cmd: <version> (<resolved path>)" or warns when the command is
not on PATH. An installed-but-unreachable binary has to fail loudly rather
than look like a successful install. The version flag is not universal, so it
tries --version, -V, -v and takes the first clean exit; tailscale is done by
hand because its CLI has only a version subcommand.

lib.sh also prepends ~/.local/bin to PATH at source time, so a module sees
what an earlier one installed (claude, the bat/fd wrappers) without waiting
for a new login shell. That lets claude.sh drop its off-PATH warning and
resolve claude by name, which doubles as the reachability check.

link_wrapper's destination check moves ahead of the has_cmd skip: with
~/.local/bin now on PATH, our own wrapper satisfies has_cmd bat, and the old
order would silently skip instead of reporting.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@samialdury
samialdury merged commit 9ffac11 into main Jul 26, 2026
7 checks passed
@samialdury
samialdury deleted the show-versions branch July 26, 2026 14:50
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