Skip to content

Instantly share code, notes, and snippets.

@jamesgecko
Created June 16, 2012 20:38
Show Gist options
  • Save jamesgecko/2942462 to your computer and use it in GitHub Desktop.
Save jamesgecko/2942462 to your computer and use it in GitHub Desktop.
Setup Ruby with rbenv on Ubuntu 12.04
# Dependencies (swiped from RVM)
sudo apt-get install build-essential bison openssl libreadline6 libreadline6-dev curl git-core zlib1g zlib1g-dev libssl-dev libyaml-dev libsqlite3-0 libsqlite3-dev sqlite3 libxml2-dev libxslt-dev autoconf libc6-dev ncurses-dev
# rbenv
cd
git clone git@github.com:sstephenson/rbenv.git ~/.rbenv
echo 'export PATH="$HOME/.rbenv/bin:$PATH"' >> ~/.bashrc
# ruby-build
mkdir -p ~/.rbenv/plugins
cd ~/.rbenv/plugins
git clone git://github.com/sstephenson/ruby-build.git
# Install Ruby
# `rbenv install` will list available versions
rbenv install 1.9.3-p194
# Set default Ruby version
rbenv global 1.9.2-p290
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment