How do you move an application to a newer version of Rails?

Hello,

I’ve got an app written in rails 1.1.2 and I need to move it to 1.1.4

Installing the older version of rails is not an option (it’s not my
system) unfortunately.

Thanks,

-Jon

1.1.2 to 1.1.4 is a fully backwards compatible release. Just run it on
1.1.4, and if you hit any issues come back and ask about them.

Chris C. wrote:

1.1.2 to 1.1.4 is a fully backwards compatible release. Just run it on
1.1.4, and if you hit any issues come back and ask about them.

Ok Good to hear. Initially, rails had complained, and had told me to
install the older version of rails. In the mean time, I ‘discovered’ a
setting config/environment.rb:

RAILS_GEM_VERSION = ‘1.1.2’

I changed that to 1.1.4 and everything seems to be working ok.

Thoughts:
I hope rails doesn’t go down the Java route and be inflated/cumbered by
backwards compatibility. Sometimes you gotta shed the old… Instead, a
version migration tool might be handy :slight_smile:

On 7/1/06, Chris C. [email protected] wrote:

1.1.2 to 1.1.4 is a fully backwards compatible release. Just run it on
1.1.4, and if you hit any issues come back and ask about them.

Except after I upgraded to 1.1.4, when I tried to do a

script/generate migration xxxx

on an app I created under 1.1.2 I got an error:

Cannot find gem for Rails =1.1.2:
Install the missing gem with ‘gem install -v=1.1.2 rails’, or
change environment.rb to define RAILS_GEM_VERSION with your desired
version.

John T. wrote:

Cannot find gem for Rails =1.1.2:
Install the missing gem with ‘gem install -v=1.1.2 rails’, or
change environment.rb to define RAILS_GEM_VERSION with your desired
version.

John,

that’s the same error I got. Try editing your config/environment.rb file
and change the line that says:

RAILS_GEM_VERSION = ‘1.1.2’

to

RAILS_GEM_VERSION = ‘1.1.4’

and report back if it doesn’t work. You might be nice and report back if
it does work too for other poeple’s enlightenment.

On 7/2/06, Jon [email protected] wrote:

and change the line that says:

RAILS_GEM_VERSION = ‘1.1.2’

to

RAILS_GEM_VERSION = ‘1.1.4’

and report back if it doesn’t work. You might be nice and report back if
it does work too for other poeple’s enlightenment.

Yes, that is what I did find I had to do.

My question is … are we going to have to do this every time Rails is
updated - edit that file for every app we have?

I believe that running “rails /path/to/app” will upgrade the
application once you installed the new release of rails.

Frederic J.

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs