Last active
January 7, 2017 00:34
-
-
Save mattes/6989885 to your computer and use it in GitHub Desktop.
rbenv one-line installer
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 | |
# curl https://gist.github.com/mattes/6989885/raw/rbenv-install.sh | bash | |
if [[ $(uname) == "Darwin" ]]; then | |
brew install rbenv ruby-build | |
echo "Add the following to ~/.bash_profile ..." | |
echo 'eval "$(rbenv init -)"' | |
else | |
# linux ... | |
git clone https://github.com/sstephenson/rbenv.git ~/.rbenv | |
git clone https://github.com/sstephenson/ruby-build.git ~/.rbenv/plugins/ruby-build | |
echo "Add the following to ~/.bash_profile ..." | |
echo "echo 'export PATH="\$HOME/.rbenv/bin:\$PATH"' >> ~/.bash_profile" | |
echo "echo 'eval "\$\(rbenv init -\)"' >> ~/.bash_profile" | |
fi |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment