Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add install_mac logic #1527

Merged
merged 3 commits into from
Mar 25, 2018
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 24 additions & 3 deletions install
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ RUBYSUFFIX=''

command_exists () {

command -v "$1" /dev/null 2&>/dev/null
command -v "${1}" >/dev/null 2>&1
}


Expand Down Expand Up @@ -115,8 +115,29 @@ install_freebsd () {
}

install_mac () {
# brew install ...
echo

local mac_deps=(curl git nodejs python3 \
openssl readline libyaml sqlite3 libxml2 \
autoconf ncurses automake libtool \
bison wget)

if ! command_exists brew; then
fatal "Homebrew (https://brew.sh/) required to install dependencies"
fi

info "Installing dependencies via brew"

brew update

for package in "${mac_deps[@]}"; do

if brew install "${package}"; then
info "${package} installed"
else
fatal "Failed to install ${package}"
fi

done
}


Expand Down