Strange Symphonies Don’t worry, be happy

11May/070

Using RubyGems package in Ubuntu Feisty Fawn apt-get Repository

After receiving a comment on my post about installing Rails on Ubuntu Feisty Fawn via RubyGems, I found, to my surprise, there exists a rubygems package in the Ubuntu Feisty Fawn universe repository. Though it is a bit outdated at 0.9.0, while the latest is 0.9.2.

So the commenter ran into a problem trying to use the repository installed rubygems and when executing in the terminal rails [image16x16:terminal], they would get a command not found error.

In actual fact, the rails program does exist but in another path ( /var/lib/gems/1.8/bin [image16x16:file] ).

There are two solutions to this. If you want to use the rubygems package from the repository, go with solution 1. Personally, I would go with solution 2.

Select your poison.

Solution 1: Modify your PATH environment variable

Open up ~/.bashrc [image16x16:file] (This is in your home directory). Append the following:
[block:file]

export PATH=$PATH:/var/lib/gems/1.8/bin

[/block]

Now either source your .bashrc (source ~/.bashrc [image16x16:terminal]) or restart your terminal. But it should work fine after this.

Solution 2: Remove the rubygems package and install via source

[block:terminal]

sudo apt-get remove rubygems

[/block]

Then continue with my guide on installing Rails on Ubuntu Feisty Fawn via RubyGems.

Related posts

Tags

Comments (0) Trackbacks (0)

No comments yet.


Leave a comment


No trackbacks yet.