Install older version of rails FAILED

Help! I need your help!!!

I have an old rail app which I made a few years ago. Never touched rails
since.

Now, I need to make it work again. I used the above command to install
rails, but I still get rails 2.1.1

gem install rails --version 1.2.6

I tried twice, and fails twice, even the installation says

Successfully installed activesupport-1.4.4
Successfully installed activerecord-1.15.6
Successfully installed actionpack-1.13.6
Successfully installed actionmailer-1.3.6
Successfully installed actionwebservice-1.2.6
Successfully installed rails-1.2.6
6 gems installed
Installing ri documentation for activesupport-1.4.4…
Installing ri documentation for activerecord-1.15.6…
Installing ri documentation for actionpack-1.13.6…
Installing ri documentation for actionmailer-1.3.6…
Installing ri documentation for actionwebservice-1.2.6…
Installing RDoc documentation for activesupport-1.4.4…
Installing RDoc documentation for activerecord-1.15.6…
Installing RDoc documentation for actionpack-1.13.6…
Installing RDoc documentation for actionmailer-1.3.6…
Installing RDoc documentation for actionwebservice-1.2.6…

Any help would be really appreciated…

Actually, I really need is rails 1.1.6, I check my config/environment.rb

This is what I got

C:\rubyapp>gem install rails --version 1.1.6
Successfully installed rails-1.1.6
1 gem installed

C:\rubyapp>rails -v
Rails 2.1.1

Now, the version seems correct, but I cannot start the webrick server.
The error message is exact the same as before…

The application I did not change a single bit since 2006.

HELP!please!!

C:\rubyapp>gem uninstall rails

Select gem to uninstall:

  1. rails-1.1.6
  2. rails-1.2.6
  3. rails-2.1.1
  4. All versions

4
Successfully uninstalled rails-1.1.6
Successfully uninstalled rails-1.2.6
Successfully uninstalled rails-2.1.1

C:\rubyapp>gem install rails --version 1.1.6
Successfully installed rails-1.1.6
1 gem installed

C:\rubyapp>rails -v
Rails 1.1.6

C:\rubyapp>cd iptv

C:\rubyapp\iptv>ruby script/server
./script/…/config/boot.rb:28: undefined method require_gem' for main:Object (N oMethodError) from c:/tools/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27: ingem_original_require’
from
c:/tools/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:
in `require’
from script/server:2

C:\rubyapp\iptv>

C:\rubyapp>rails -v
Rails 2.1.1

C:\rubyapp>gem uninstall rails

Select gem to uninstall:

  1. rails-1.1.6
  2. rails-1.2.6
  3. rails-2.1.1
  4. All versions

4
Successfully uninstalled rails-1.1.6
Successfully uninstalled rails-1.2.6
Successfully uninstalled rails-2.1.1

C:\rubyapp>gem install rails --version 1.1.6
Successfully installed rails-1.1.6
1 gem installed

C:\rubyapp>rails -v
Rails 1.1.6

C:\rubyapp>cd iptv

C:\rubyapp\iptv>ruby script/server
./script/…/config/boot.rb:28: undefined method require_gem' for main:Object (N oMethodError) from c:/tools/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27: ingem_original_require’
from
c:/tools/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:
in `require’
from script/server:2

C:\rubyapp\iptv>

C:\rubyapp>rails -v
Rails 2.1.1

C:\rubyapp>gem uninstall rails

Select gem to uninstall:

  1. rails-1.1.6
  2. rails-1.2.6
  3. rails-2.1.1
  4. All versions

4
Successfully uninstalled rails-1.1.6
Successfully uninstalled rails-1.2.6
Successfully uninstalled rails-2.1.1

C:\rubyapp>gem install rails --version 1.1.6
Successfully installed rails-1.1.6
1 gem installed

C:\rubyapp>rails -v
Rails 1.1.6

C:\rubyapp>cd iptv

C:\rubyapp\iptv>ruby script/server
./script/…/config/boot.rb:28: undefined method require_gem' for main:Object (N oMethodError) from c:/tools/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27: ingem_original_require’
from
c:/tools/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:
in `require’
from script/server:2

On 17 Jan 2009, at 13:10, Roseanne Z. wrote:

Now, the version seems correct, but I cannot start the webrick server.
The error message is exact the same as before…

The application I did not change a single bit since 2006.

The problem you’ve got here is probably that the version of rubygems
you’ve got is too new for the version of rails you’ve got.
Replacing calls to require_gem with calls to gem should do the trick.
Fred

I think you have to quote the version number.

e.g. gem install rails --version ‘1.2.6’

Huge thanks, Frederick!!!

WOW, you are exactly right, now, the server started, and the app runs.

BIG release sigh…

Of course, I need to make the database work again…

Maybe, I need to change to the old version of gem?

Roseanne

Frederick C. wrote:

On 17 Jan 2009, at 13:10, Roseanne Z. wrote:

Now, the version seems correct, but I cannot start the webrick server.
The error message is exact the same as before…

The application I did not change a single bit since 2006.

The problem you’ve got here is probably that the version of rubygems
you’ve got is too new for the version of rails you’ve got.
Replacing calls to require_gem with calls to gem should do the trick.
Fred