provision: report installed tool versions per module#9
Merged
Conversation
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>
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.
Each module now ends by running what it installed through
show_versions(), which printscmd: <version> (<resolved path>)or warns when the command is not onPATH. 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,-vand takes the first clean exit (tmuxneeds-V,digneeds-v).tailscaleis done by hand — its CLI has only aversionsubcommand, no flag.lib.shalso prepends~/.local/bintoPATHat source time, so a module sees what an earlier one installed (claude, thebat/fdwrappers) without waiting for a new login shell;run-all.shruns modules as children, which inherit it. That letsclaude.shdrop its off-PATH warning and resolveclaudeby name, which doubles as the reachability check.link_wrapper's destination check moves ahead of thehas_cmdskip: with~/.local/binnow onPATH, our own wrapper satisfieshas_cmd bat, and the old order would silently skip instead of reporting.provision/test/inside.shcovers all of it — every tool reports a version, none report?, and the claude off-PATH case now assertslib.shrepairedPATHinstead of warning. Locally only./scripts/test-install.shran (green); the container suite is left to CI.🤖 Generated with Claude Code