5 ms·
> Under no circumstance should you install Ruby, Rubygems or any Ruby-related packages from apt-get I really wish the RoR book I was reading had told me that b
by aberkowitz 16y ago
> Under no circumstance should you install Ruby, Rubygems or any Ruby-related packages from apt-get
I really wish the RoR book I was reading had told me that before I spent multiple hours trying to properly setup Rails.
- mapleoin 16y agoI'm very skeptical about this sort of advice, especially when it is motivated by We do Ruby, we know what’s best. Trust us.
- aberkowitz 16y agoI'm not sure where your skepticism is coming from, but I can assure you that I would have saved countless hours had I begun with a more current version of Rubygems and Ruby.
- deleted 16y ago[deleted]
- bricestacey 16y agoYet it's very strong advice.
- eccp 16y agoI think the same way, I would expect something like the following from a book author: "Since we're going to install Rails 3 which is newer than the version packaged/available in Ubuntu 10.10, we will do a separate install which is not compatible with the package manager, etc."
- halostatue 16y agoDespite much effort from some Debian maintainers, packaged Ruby remains hopelessly broken on those systems. Some of the breakage is deliberate because Debian's policies.
- samdk 16y agoIt really is very good advice, and installing Ruby/RubyGems through the package manager is almost never a good idea (especially on Debian-based distros) for several reasons. Ruby is a language that moves very, very quickly. On "cutting-edge" distros like Fedora and Arch it's not nearly as much of an issue, but not having to wait to get new language versions is very convenient. More importantly, though, is that the version of RubyGems distributed through Debian's (and Debian descendents like Ubuntu's) package repositories is crippled. Gem normally includes a very important command called 'gem update --system' that lets you upgrade gem itself. The opinion of the Debian package maintainers is that all upgrades should be handled through the package manager. This makes sense from a system administration perspective, but it's a huge pain when you're trying to do Ruby development, because important gems like Rails often require a fairly new version of RubyGems. (And Ruby libraries get updated much more frequently than the language itself.) For the above reasons, doing Ruby stuff on Debian/Ubuntu without using RVM is a huge pain. Even if you manage to get everything working, an update to gem or something else may break it a week later. While RVM isn't as essential on other distros (like Fedora, which I did Ruby dev on for a long time before learning about RVM), it's still massively convenient. You can ensure that you have a consistent development environment across computers and operating systems (which I find is especially useful when deploying to a server, since I use different Linux distros for everyday use than I do for hosting things), you can easily switch between Ruby versions (I have one project still on 1.8.7, and I do the rest of my stuff on 1.9.x--switching between them is as simple as typing rvm $VERSION), and it deals with all of the icky bits of managing multiple versions of gems (to go with your multiple versions of Ruby) for you. RVM is awesome, and makes lots of the headaches that surround Ruby development go away. Use it.
- zppx 16y ago> "Ruby is a language that moves very, very quickly." and later > "This makes sense from a system administration perspective, but it's a huge pain when you're trying to do Ruby development" It's a developer's world. Having been a Rails programmer working on some internals projects in the company that I used to work, I like both Ruby and Rails. But now I'm' working as an operations guy (ie, a sysadmin) in a new company, we came short of adopting redmine and maybe opening the road for more ruby and rails software to be used, we already use puppet and so every sysadmin now knows ruby, so it would be good to include some more ruby to internal use, but it was just a pain in the ass to maintain the rails-based infrastructure, in both Debian and CentOS, the distributions that we use. Fedora and Arch is not used in the servers, so it cannot be used. This is old, and just touches one aspect of the problems (shared hosting, which I do not deal with), but it does have some good rants, specially the point 2 of "How it could be better": http://blog.dreamhost.com/2008/01/07/how-ruby-on-rails-could-be-much-better/ http://blog.dreamhost.com/2008/01/07/how-ruby-on-rails-could...
- tjogin 16y agoYeah, why would Rubyists know anything about setting up Ruby?
- SkyMarshal 16y agoIsn't installing Ruby from apt-get ok, since RVM just manages that as the 'system' ruby alongside all the other Ruby's RVM can install and manage? Not sure about gems or other packages though.
- telemachos 16y agoWhat the blogger probably meant was "don't use Ubuntu's Ruby" for any serious development (since it's out of date and crippled). As far as it goes, you can certainly install Ruby with apt-get or aptitude, but I think the response then would be "Why bother?", assuming you're not going to use it anyhow. One other thing: rvm doesn't really "manage" the system Ruby. You can issue the command 'rvm system', but what that really does is remove the rvm directories from your $PATH. rvm itself never touches the Ruby interpreter or libraries installed via APT.