Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I want to install Ruby on Rails (I'm running a FreeBSD but don't want to use Ports for RoR) so this is a more generic unix/RoR question.

Simply what is the best way to install Rake.

http://rake.rubyforge.org/ suggests:

% ruby install.rb

or

gem install --remote rake

I have installed Ruby 1.9 and the path to its lib is

/usr/local/lib/ruby/

I'm not sure the best way of the two above options or if there any other recommendations. (Essentially, FreeBSD is still on Ruby 1.8 and so I just want to do all RoR in a self contained install, and not have the Ports gems mixed with other gems that are not in Ports).

share|improve this question
add comment

1 Answer

Ruby 1.9.2 (lang/ruby19 port) ships with rake-0.8.7.

You may completely ignore Ruby 1.8 on FreeBSD, by a) deleting it and b) adding to /etc/make.conf the line:

RUBY_DEFAULT_VER=1.9

Then install lang/ruby19 port, update rubygems (as root):

# gem update rdoc
# gem update --system

and finally, install rails:

# gem install rails

And forget about any gems from ports, use gem tool to manage gems.

If you want a non-system rails setup, install shells/bash port and manually install RVM https://rvm.beginrescueend.com/. It perfectly works in FreeBSD with bash as your shell.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.