开发者

rails -v returns 2.3.5 but gem uninstall rails offers to uninstall version 3.1

开发者 https://www.devze.com 2023-03-30 03:16 出处:网络
I am trying upgrade Rails.I am pretty sure that Rails 3.1 is now installed, however my rails apps still have no Gemfile, and rails -v returns 2.3.5.When I type \"gem uninstall rails\"I 开发者_开发知识

I am trying upgrade Rails. I am pretty sure that Rails 3.1 is now installed, however my rails apps still have no Gemfile, and rails -v returns 2.3.5. When I type "gem uninstall rails" I 开发者_开发知识库get:

aheine@ubuntu:~/www$ gem uninstall rails

Select gem to uninstall:
 1. rails-3.0.9
 2. rails-3.1.0.rc1
 3. rails-3.1.0.rc5
 4. All versions

How can I get rid of Rails 2, and make rails 3 the default version to use?

I am using Ubuntu 11.04


Your running with the system provided Rails, run apt-get remove rails and then you may need to make a configuration change so the system can find the proper rails command. So see if that works and then try running rails -v if that returns command not found add this line to the beginning of your .bashrc file in your home directory.

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

After that's done open a new shell and try running rails -v again.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号