How to go about installing and configuring Ruby Version Manager on OS X version 10.5.8.

Install RVM.

I would recommend the installation which uses the code from github, as described in the excellent instructions on the RVM install page.

Install some common rubies.

$ rvm install 1.8.7
$ rvm list known | grep jruby
jruby-1.2.0
jruby-1.3.1
jruby-1.4.0
jruby-1.5.1
jruby(-1.5.2)
jruby-head
$ rvm install jruby-head
$ rvm install 1.9.2-head

Check the installation.

$ rvm use 1.9.2-head
info: Using ruby 1.9.2 head

$ ruby -v
ruby 1.9.2p0 (2010-08-18 revision 29034) [i386-darwin9.8.0]

$ irb
ruby-1.9.2-head > puts "hello"
hello
=> nil 
ruby-1.9.2-head > exit

Install Rails.

$ gem install rails --pre

$ rails -v
Rails 3.0.0.rc2

Check that your gems are installed correctly.

$ gem list --local

*** LOCAL GEMS ***

abstract (1.0.0)
actionmailer (3.0.0.rc2)
actionpack (3.0.0.rc2)
activemodel (3.0.0.rc2)
activerecord (3.0.0.rc2)
activeresource (3.0.0.rc2)
activesupport (3.0.0.rc2)
arel (1.0.0.rc1)
builder (2.1.2)
bundler (1.0.0)
erubis (2.6.6)
i18n (0.4.1)
mail (2.2.5)
mime-types (1.16)
polyglot (0.3.1)
rack (1.2.1)
rack-mount (0.6.13)
rack-test (0.5.4)
rails (3.0.0.rc2)
railties (3.0.0.rc2)
rake (0.8.7)
thor (0.14.0)
treetop (1.4.8)
tzinfo (0.3.23)

Check that your gems are in the right place.

The INSTALLATION DIRECTORY, RUBY EXECUTABLE and EXECUTABLE DIRECTORY should all be isolated under the $HOME/.rvm directory and then categorised by the version of Ruby that we are using, in this case 1.9.2-head.

$ gem environment
RubyGems Environment:
- RUBYGEMS VERSION: 1.3.7
- RUBY VERSION: 1.9.2 (2010-08-18 patchlevel 0) [i386-darwin9.8.0]
- INSTALLATION DIRECTORY: /Users/hgilmour/.rvm/gems/ruby-1.9.2-head
- RUBY EXECUTABLE: /Users/hgilmour/.rvm/rubies/ruby-1.9.2-head/bin/ruby
- EXECUTABLE DIRECTORY: /Users/hgilmour/.rvm/gems/ruby-1.9.2-head/bin
- RUBYGEMS PLATFORMS:
  - ruby
  - x86-darwin-9
- GEM PATHS:
  - /Users/hgilmour/.rvm/gems/ruby-1.9.2-head
  - /Users/hgilmour/.rvm/gems/ruby-1.9.2-head@global
- GEM CONFIGURATION:
  - :update_sources => true
  - :verbose => true
  - :benchmark => false
  - :backtrace => false
  - :bulk_threshold => 1000
  - :sources => ["http://gems.rubyforge.org/", "http://gems.github.com"]
  - "rdoc" => "--inline-source --line-numbers --format=darkfish"
- REMOTE SOURCES:
  - http://gems.rubyforge.org/
 - http://gems.github.com
Filed under: tools

comments

There are no comments.