TILbrew

#TIL 27 - Install Homebrew manually

Jul 6, 2022 · Dung Huynh

What

Install Homebrew to a local directory without root access.

Why

Some servers don't allow sudo. Local installation works without system permissions.

How

# Clone Homebrew
git clone https://github.com/Homebrew/brew homebrew

# Add to PATH
eval "$(homebrew/bin/brew shellenv)"

# Initialize
brew update --force --quiet
chmod -R go-w "$(brew --prefix)/share/zsh"