The latest version of rails installed on my mac is 3.0.0.beta
gem list returns rails (3.0.0.beta, 2.3.5, 2.3.4, 2.3.2, 2.2.2, 1.2.6)
I want to create a new project using version 2.3.5
So I run: rails _2.3.5_ myProject
But it returns the following error
$ rails _2.3.5_ photosbackup
/Library/Ruby/Site/1.8/rubygems.rb:777:in `report_activate_error': R开发者_如何学JAVAubyGem version error: railties(3.0.0.beta not = 2.3.5) (Gem::LoadError)
from /Library/Ruby/Site/1.8/rubygems.rb:211:in `activate'
from /Library/Ruby/Site/1.8/rubygems.rb:1056:in `gem'
from /usr/bin/rails:18
Any idea how I can create a new project using version 2.3.5?
Thanks
I think you can just uninstall the previous Rails versions.
Which can be problematic - I have a number of Rails 2.3.5 (and earlier) apps in production that require maintenance and won't be upgraded to the new version.
So what I recommend in this situation is having a look at RVM - it lets you install and manage multiple versions of Ruby, and provides isolation between sets of Gems. I now run a Ruby 1.9.1 with Rails 3 and friends in isolation from my default system settings which let me do my day to day work.
even i had the same problem but the following command worked for me rails 2.3.5 new myProject
精彩评论