Skip to content

Instantly share code, notes, and snippets.

@JesseHerrick
Last active December 31, 2015 10:49
Show Gist options
  • Save JesseHerrick/7975465 to your computer and use it in GitHub Desktop.
Save JesseHerrick/7975465 to your computer and use it in GitHub Desktop.
Setup RBEnv on Ubuntu. A fork of [my other script.](https://gist.github.com/JesseHerrick/7728497)
# Install git for RBEnv and gcc for Ruby.
sudo apt-get install git gcc
git clone git://github.com/sstephenson/rbenv.git $HOME/.rbenv
# Create /etc/init.d/rbenv.sh
sudo touch /etc/init.d/rbenv.sh
sudo cat <<EOF > /etc/init.d/rbenv.sh
export RBENV_ROOT=$HOME/.rbenv
export PATH="${RBENV_ROOT}/bin:$PATH"
eval "$(rbenv init -)"
EOF
. /etc/init
# Download rubybuild
git clone https://github.com/sstephenson/ruby-build.git $HOME/.rbenv/plugins/ruby-build
echo "RBEnv installed!"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment