Sponsored by Gluten Free Waffles and Sliced Bananas

Friday, December 7, 2012

Fixing "gem: command not found" after installing RVM (Ubuntu)

6:51 PM Posted by Tyson Nero , , No comments
After installing RVM and Ruby on my Ubuntu 10.04 machine, I installed Compass via "gem install compass". When I tried to run Compass from the command line, I received "compass: command not found".

It seemed my install of Ruby was not correctly added to the path. I quickly found some fixes via Google that involved modifying a couple lines of the .bashrc file. However, it turns out that the simplest fix would be to add the following the end of the .bashrc file...

PATH=$PATH:$HOME/.rvm/bin # Add RVM to PATH for scripting

Hope this helps.

------------

UPDATE

It seems I also had to set the path directly to my Ruby bin directory:
PATH=$PATH:$HOME/.rvm/gems/ruby-1.9.3-p327/bin

0 comments:

Post a Comment