Installing Ruby RVM on Ubuntu 12.10

I've never used Ruby even though it's apparently the language of the hour (or maybe some hours ago - I'm often late on such stuff), but had to use it today to run some scripts. I didn't know what RVM was until a couple of hours ago, but when I had to use it, I found out that the package doesn't exist on 12.10 :-/

There's probably some PPA out there with updated packages, but a quick search didn't reveal any, so I decided to install it manually. As the packaged Ruby is kinda outdated, and doesn't match with some of the gems, I also installed a fresh version of that. To avoid clashing with anything that might need the packaged version, I installed it in my home directory. Luckily the RVM packagers made it very simple to do.


sudo apt-get install libxslt1.1 libxslt-dev xvfb build-essential git-core curl
Maybe they're not all needed for ruby/rvm, but I followed an instruction on how to run Cumbumber tests for ownCloud. Install RVM (from the RVM install page):
\curl -L | bash -s stable --ruby
Add code to source some init code to your .bashrc (no idea what it does):
echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"' >> ~/.bashrc
Add the bin directory to your PATH:
echo 'export PATH=$HOME/.rvm/bin:$PATH' >> ~/.bashrc
And source it:
. .bashrc
Install necessary dependencies:
bundle install

That's it. Feel free to comment, but I most likely can't answer any questions, because all I did was to collect some snippets from various sources and boil them down to some easy steps :-)

Flattr this!

Posted in Ruby, Ubuntu. Tags: , , . 4 Comments »