Add a static `display.customLine` config field that renders a user-defined
phrase (max 80 chars) in Claude orange on the project line, joined with
the standard │ separator.
- config.ts: add customLine to HudConfig.display with validation
- colors.ts: add claudeOrange() using 256-color (38;5;208)
- project.ts: append customLine to expanded mode project line
- session-line.ts: append customLine to compact mode parts
- setup.md: add "Custom line" option to Step 4
- configure.md: add Q5 Custom Line to both Flow A and Flow B
* fix: detect macOS and show restart hint when HUD initializes without stdin (closes#213)
* fix: prompt user to restart Claude Code after config write for HUD setup
* fix: update assertion to check if output starts with initializing message
* Align restart messaging in docs
---------
Co-authored-by: Jarrod Watts <jarrod@cubelabs.xyz>
Users running Claude Code with a custom config directory (e.g.
CLAUDE_CONFIG_DIR=~/.claude-work) had the plugin installed to that
directory, but /claude-hud:setup always looked in the hardcoded
~/.claude path, causing it to report the plugin as not installed.
Replace all hardcoded ~/.claude/ references with
${CLAUDE_CONFIG_DIR:-$HOME/.claude} so that setup correctly resolves
the plugin cache, settings.json, and config.json under whatever config
directory Claude Code is using.
Also fix glob-inside-quotes bug in the temp_local_* cleanup commands
(quotes prevented wildcard expansion).
Co-authored-by: dennis <dennis@brevitydata.net>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
* fix: use version-based sorting instead of mtime for plugin selection
The statusline command used `ls -td` (sort by modification time) to
select the latest plugin version from the cache directory. When multiple
versions coexist after an upgrade, the older version can have a newer
mtime, causing the statusline to run the wrong version.
This led to a real issue where v0.0.7 (no proxy support) was selected
over v0.0.9, causing persistent 403 errors on the usage API for users
behind a required proxy.
Replace `ls -td | head -1` with `ls -d | sort -V | tail -1` to sort
by version number. Apply the equivalent fix for Windows PowerShell
using `[version]` casting.
Fixes#198
* docs: make setup version lookup portable
* docs: avoid login shell in setup command
---------
Co-authored-by: Jarrod Watts <jarrod@cubelabs.xyz>
* feat(config): add showSessionName toggle (default off)
Session name display from #155 is now opt-in via display.showSessionName
config. This addresses user feedback requesting the ability to hide the
session name. Added to setup onboarding and configure command flows.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* test(docs): cover session-name default behavior
---------
Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: Jarrod Watts <jarrod@cubelabs.xyz>
New default: model+project on line 1, context+usage bars combined on line 2.
All optional features (tools, agents, todos) hidden by default with
setup onboarding step to enable them.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The Bash tool on Windows uses Git Bash as its interpreter, so `uname -s`
returns MINGW even when the user launched Claude Code from PowerShell.
This caused setup to generate bash commands that fail in PowerShell.
Fix: Instruct Claude to use the Platform value from its environment
context (darwin/linux/win32) instead of running uname. This correctly
identifies the user's actual platform regardless of the Bash tool's
environment.
- darwin → bash commands (macOS)
- linux → bash commands (all distros: Ubuntu, NixOS, Arch, etc.)
- win32 → PowerShell commands (works on PowerShell, cmd.exe, Git Bash)
Fixes#90
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Failed or interrupted plugin installations can leave inconsistent state:
- Cache exists but not in registry (orphaned)
- Registry entry exists but no cache (stale)
- temp_local_* files left from interrupted installs
New Step 0 in setup.md:
- Detects cache/registry mismatch
- Finds leftover temp files
- Provides cleanup commands for macOS/Linux/Windows
- Includes EXDEV check for Linux (consolidated from Step 1)
Also consolidates EXDEV detection into Step 0 instead of buried in Step 1.
Fixes#59, #62, #60
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
* fix: detect EXDEV cross-device error on Linux installation
When plugin path is not found during setup on Linux, check if /tmp and
~/.claude are on different filesystems. If so, provide the TMPDIR
workaround to users.
Fixes#52
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* feat(setup): dynamic platform and runtime detection
- Detect macOS/Linux/Windows and generate appropriate command
- Use absolute runtime path (fixes PATH issues with mise/nvm)
- Prefer bun when available for faster startup
- Add user verification step with debugging if setup fails
- Keep dynamic plugin path lookup for automatic updates
Addresses: #5, #11, PR #19, PR #22🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* fix: address review feedback for robust cross-platform support
- Use `command -v` instead of `which` (POSIX compliant)
- Add runtime path validation step
- Add Windows bun support with proper detection
- Use `Join-Path` for Windows path handling
- Add WSL-specific guidance
- Add PowerShell execution policy troubleshooting
- Add expected execution time (1 second)
- Include asdf in version manager list
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* fix: address minor review feedback
- Add placeholder substitution note at top
- Use basename for more robust bun detection
- Clarify GitHub star prompt
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* fix: harden edge case handling
- Add plugin path validation for both platforms
- Windows: explicit error if neither bun nor node found
- Windows: quote runtime path to handle spaces in paths
- Windows: use full cmdlet names (Sort-Object, Get-ChildItem) for clarity
- Add note that Step 2 test catches broken binaries
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* fix(setup): address code review feedback
- Fix MINGW/MSYS/CYGWIN detection: Git Bash users now handled correctly
- Add quotes around runtime path to handle spaces in paths
- Add Windows-specific settings.json path guidance
- Clarify Step 3 JSON merge edge cases (missing file, invalid JSON)
- Document bun's native TypeScript support
- Add auto-update documentation note
- Add symlink troubleshooting for version managers
- Add stale config detection in debugging section
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* docs(setup): address additional code review feedback
- Add explicit Git Bash/MSYS2/Cygwin user guidance
- Change test timeout from "1 second" to "a few seconds"
- Add readlink -f as alternative to realpath
- Add note about re-running setup if HUD stops working
- Check gh CLI availability before star suggestion
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
Uses time-sorted ls to find latest version - no external scripts needed.
Works on all macOS/Linux versions.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
- setup.md now explicitly instructs to use the variable, not resolve it
- Version updated to 0.0.1 for initial release
🤖 Generated with [Claude Code](https://claude.com/claude-code)
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>