Last active
August 3, 2022 08:21
-
-
Save giseongeom/25da41fca047d9bfc72cf8ef8717ab55 to your computer and use it in GitHub Desktop.
Install (Linux) Homebrew non-interactively
This file contains 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
#!/usr/bin/env bash | |
set -e | |
# Unattended install of homebrew | |
# https://docs.brew.sh/Installation#unattended-installation | |
export NONINTERACTIVE=1 && /bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)" | |
# Adding Homebrew to your PATH | |
# https://docs.brew.sh/Homebrew-on-Linux | |
test -d ~/.linuxbrew && eval "$(~/.linuxbrew/bin/brew shellenv)" | |
test -d /home/linuxbrew/.linuxbrew && eval "$(/home/linuxbrew/.linuxbrew/bin/brew shellenv)" | |
test -r ~/.bash_profile && echo "eval \"\$($(brew --prefix)/bin/brew shellenv)\"" >> ~/.bash_profile | |
echo "eval \"\$($(brew --prefix)/bin/brew shellenv)\"" >> ~/.profile | |
# | |
echo "linuxbrew Installation is Done!" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment