Skip to content

Instantly share code, notes, and snippets.

@juno
Created November 10, 2012 11:28
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 2 You must be signed in to fork a gist
  • Save juno/4050823 to your computer and use it in GitHub Desktop.
Save juno/4050823 to your computer and use it in GitHub Desktop.
Using ruby-1.9.3-p327 with ruby-env and ruby-build

Using ruby-1.9.3-p327 with ruby-env and ruby-build

Prerequisite

  • Mac OS X Mountain Lion (10.8.2)
  • Homebrew
  • readline
  • rbenv

Install or update ruby-build

Install ruby-build as a rbenv plugin:

$ mkdir -p ~/.rbenv/plugins
$ cd ~/.rbenv/plugins
$ git clone git://github.com/sstephenson/ruby-build.git

or update ruby-build:

$ cd ~/.rbenv/plugins/ruby-build
$ git pull

Install ruby-1.9.3-p327

$ brew link readline
$ CONFIGURE_OPTS="--with-readline-dir=/usr/local" rbenv install 1.9.3-p327
Downloading http://pyyaml.org/download/libyaml/yaml-0.1.4.tar.gz...
Installing yaml-0.1.4...
Installed yaml-0.1.4 to /Users/juno/.rbenv/versions/1.9.3-p327
Downloading http://ftp.ruby-lang.org/pub/ruby/1.9/ruby-1.9.3-p327.tar.gz...
Installing ruby-1.9.3-p327...
Installed ruby-1.9.3-p327 to /Users/juno/.rbenv/versions/1.9.3-p327
$ brew unlink readline

Make ruby-1.9.3-p327 default

$ rbenv global 1.9.3-p327
$ ruby -v
ruby 1.9.3p327 (2012-11-10 revision 37606) [x86_64-darwin12.2.0]

done.

@vmu9999
Copy link

vmu9999 commented Feb 5, 2013

Thanks for the writeup.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment