Skip to content

Instantly share code, notes, and snippets.

@calumhalcrow
Forked from parasquid/README.md
Created December 6, 2013 04:07
Show Gist options
  • Save calumhalcrow/7818410 to your computer and use it in GitHub Desktop.
Save calumhalcrow/7818410 to your computer and use it in GitHub Desktop.

Installs ruby-2.0.0-p247 on ubuntu via checkinstall so it's in your package manager and you can remove it.

Quick install:

curl -Lo- https://gist.github.com/parasquid/5624732/raw/install-ruby-2-ubuntu.sh | bash
#!/usr/bin/env bash
set -e
RUBY_V='ruby-2.0.0-p247'
sudo apt-get install checkinstall -y
sudo apt-get build-dep ruby1.9.1 -y
wget -c http://ftp.ruby-lang.org/pub/ruby/2.0/$RUBY_V.tar.gz
tar xzf $RUBY_V.tar.gz
cd $RUBY_V
./configure --enable-load-relative
make
sudo checkinstall -y -D \
--pkgversion 2.0.0-p247 \
--provides "ruby-interpreter"
# install ruby gems
sudo apt-get install libyaml-ruby libzlib-ruby -y
wget -c http://production.cf.rubygems.org/rubygems/rubygems-2.1.7.tgz
tar -xzf rubygems-2.1.7.tgz
cd rubygems-2.1.7
sudo ruby setup.rb
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment