headroom/plugins
Krishna adaeb88a4d
fix(openclaw): detect uv-installed headroom binary in ~/.local/bin (#1459)
## Description
When `headroom-ai` is installed via `uv tool install headroom-ai`, the
binary lands at `~/.local/bin/headroom`. The plugin's autoStart launcher
detection did not find it because the PATH check used `sh -lc` which may
not source user shell config (`.zshrc`, `.bash_profile`) on all systems.
This PR adds explicit uv path detection and fixes the shell invocation
flag.

Related to #419

## Type of Change
- [x] Bug fix (non-breaking change that fixes an issue)
- [ ] New feature
- [ ] Breaking change
- [ ] Documentation update
- [ ] Performance improvement
- [ ] Code refactoring

## Changes Made
- Switch PATH check from `sh -lc` to `sh -c` in `proxy-manager.ts`
- Add explicit uv tool install detection checking
`~/.local/bin/headroom`

## Testing
- [ ] Unit tests pass (`pytest`)
- [ ] Linting passes (`ruff check .`)
- [ ] Type checking passes (`mypy headroom`)
- [x] Manual testing performed

### Test Output
```text
Status: loaded
Version: 0.27.0
Capabilities:
  context-engine: headroom
Tools:
  headroom_retrieve
```

## Real Behavior Proof
- Environment: EndeavourOS x86_64, OpenClaw 2026.6.10, headroom-ai
0.27.0 via uv
- Exact command / steps: `uv tool install headroom-ai` then `openclaw
gateway restart`
- Observed result: Before fix — autoStart failed with "Headroom proxy
not detected on default endpoints" even though binary exists at
`~/.local/bin/headroom`. After fix — plugin loads and connects
correctly.
- Not tested: Windows, Docker runtime

## Review Readiness
- [x] I have performed a self-review
- [x] This PR is ready for human review

## Additional Notes
Reproduced while debugging the npm package staleness issue in #419.
Affects any user following the standard `uv tool install` workflow on
Linux/macOS.
2026-06-30 14:18:06 -05:00
..
headroom-agent-hooks ci(release): align manifest + pyproject + package.json to 0.22.3 2026-05-25 18:41:38 -07:00
headroom-oauth2 chore: remove committed node_modules + stray/internal markdown (repo hygiene) (#1528) 2026-06-27 23:32:54 -07:00
hermes fix(ccr): make headroom_retrieve a hash-only full-content lookup (#1532) 2026-06-28 10:32:43 -07:00
openclaw fix(openclaw): detect uv-installed headroom binary in ~/.local/bin (#1459) 2026-06-30 14:18:06 -05:00
opencode fix(opencode): preserve custom OpenAI gateway paths (#1596) 2026-06-30 08:41:42 -07:00