Changing app version

I’m having difficulties changing the version of rails my app uses. I
changed the version in environment.rb from 2.0.2 to 3.0.3:
RAILS_GEM_VERSION = ‘3.0.3’ unless defined? RAILS_GEM_VERSION

(3.0.3 is installed:>gem list |grep rails
rails (3.0.3, 2.0.2))

‘rake rails:update’ gives:
rake aborted!
can’t activate rails (= 2.0.2, runtime) for [], already activated
rails-3.0.3 fo
r []
D:/RailsInstaller/Ruby1.8.7/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2383:i
n `raw_load_rakefile’
(See full trace by running task with --trace)

It’s driving me crazy…
Does anyone know what’s going on pls?

In your vendor folder of your app, is there a rails folder? If there is
it
means that you app is frozen to the version of rails in that folder
(2.0.2).
To get it to use the version installed on your OS, 3.0.3, you will need
to
remove this folder. I would copy it out to somewhere safe. The second
your
app tries to run under rail 3.0.3 you’re going to experience a bunch of
deprecation errors. Having the saved rails folder copy will allow you to
go
back to the old version by just putting it back in.

Here is a good article on freezing your Rails app that you might find
helpful.

B.

Hmm, no rails folder in vendor…

On 25 February 2011 17:53, Kelly P. [email protected] wrote:

I’m having difficulties changing the version of rails my app uses. I
changed the version in environment.rb from 2.0.2 to 3.0.3:
RAILS_GEM_VERSION = ‘3.0.3’ unless defined? RAILS_GEM_VERSION

That’s a bit of a big jump. If I were you, I’d get the app working
nicely (with all tests passing…) on 2.3.11, then move up to 3.x

Check out this gem for testing for Rails 3 preparedness: