Skip to content

fix: print PATH setup instructions when install dir is not in PATH#41

Merged
kylecarbs merged 1 commit into
mainfrom
install-path-hint
Jun 11, 2026
Merged

fix: print PATH setup instructions when install dir is not in PATH#41
kylecarbs merged 1 commit into
mainfrom
install-path-hint

Conversation

@kylecarbs

Copy link
Copy Markdown
Member

On macOS, /usr/local/bin is not user-writable (Homebrew lives in /opt/homebrew on Apple Silicon), so the installer falls back to ~/.local/bin, which is not in the default macOS PATH. The script only printed a bare warning that was easy to miss in curl | sh output and offered no remediation.

The install location logic is unchanged. When the install directory is not in PATH, the script now:

  • Prints the exact line to append for the user's login shell (~/.zshrc, ~/.bashrc, or fish_add_path), using $HOME-relative paths where possible.
  • Mentions rerunning with sudo BOO_INSTALL_DIR=/usr/local/bin for a system-wide install.

Example output for a zsh user:

warning: /Users/me/.local/bin is not in your PATH
To add it, run:
  echo 'export PATH="$HOME/.local/bin:$PATH"' >> ~/.zshrc
then restart your shell.

For a system-wide install instead, rerun with:
  curl -fsSL https://raw.githubusercontent.com/coder/boo/main/install.sh | sudo BOO_INSTALL_DIR=/usr/local/bin sh
Testing and decisions
  • Verified with shellcheck (clean).
  • Ran the script end-to-end with SHELL set to zsh, bash, fish, and dash; each prints the correct instructions, and no warning is printed when the install dir is already in PATH.
  • Chose actionable messaging over sudo escalation: prompting for sudo inside curl | sh hangs unattended installs, and modern installers (rustup, uv, bun) install user-local without sudo.

Generated by Coder Agents on behalf of @kylecarbs.

@kylecarbs kylecarbs merged commit 75be535 into main Jun 11, 2026
5 checks passed
@kylecarbs kylecarbs deleted the install-path-hint branch June 11, 2026 20:07
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