This project is archived and is in readonly mode.

#3923 ✓wontfix
Conrad Taylor

Enhancement Request: generate application using previous Rails version

Reported by Conrad Taylor | February 10th, 2010 @ 03:40 PM

After installing Rails 3.0 beta, it's a bit cumbersome to target a previous version of the framework. Thus, I propose that the following option be added to the rails command:

-u, [--use=RAILS_VERSION] # Rails framework version to use to generate application.

e.g.

rails --use=2.3.5 -d database_engine application_name
rails -u 2.3.5 -d database_engine application_name

Comments and changes to this ticket

  • Matt Jones

    Matt Jones February 10th, 2010 @ 05:29 PM

    Does the standard gem wrapper method:

    rails _2.3.5_ ...args...
    

    Not work for this case?

  • Conrad Taylor

    Conrad Taylor February 11th, 2010 @ 02:38 AM

    After trying the standard gem wrapper, I'm seeing the following issue:

    
    $ rvm ruby-head
    
    $ ruby -v
    ruby 1.9.2dev (2010-01-18 trunk 26340) [powerpc-darwin9.8.0]
    
    $ gem list rails
    
    *** LOCAL GEMS ***
    
    rails (3.0.0.beta, 3.0.pre, 2.3.5)
    
    $ gem list rails
    
    *** LOCAL GEMS ***
    
    rails (3.0.0.beta, 2.3.5)
    
    $ rails _2.3.5_ blog235
    /opt/local/lib/ruby/gems/1.9.1/gems/rubygems-update-1.3.5/lib/rubygems.rb:827:in `report_activate_error': RubyGem version error: railties(3.0.pre not = 2.3.5) (Gem::LoadError)
        from /opt/local/lib/ruby/gems/1.9.1/gems/rubygems-update-1.3.5/lib/rubygems.rb:261:in `activate'
        from /opt/local/lib/ruby/gems/1.9.1/gems/rubygems-update-1.3.5/lib/rubygems.rb:68:in `gem'
        from /Users/conradwt/.rvm/gems/ruby-head/bin/rails:18:in `<main>'
    
    $ rvm system
    
    $ ruby -v
    ruby 1.9.1p376 (2009-12-07 revision 26041) [powerpc-darwin9]
    
    $ gem list rails
    
    *** LOCAL GEMS ***
    
    rails (3.0.0.beta, 2.3.5)
    
    $ rails _2.3.5_ blog235
    /opt/local/lib/ruby/gems/1.9.1/gems/rubygems-update-1.3.5/lib/rubygems.rb:827:in `report_activate_error': RubyGem version error: railties(3.0.0.beta not = 2.3.5) (Gem::LoadError)
        from /opt/local/lib/ruby/gems/1.9.1/gems/rubygems-update-1.3.5/lib/rubygems.rb:261:in `activate'
        from /opt/local/lib/ruby/gems/1.9.1/gems/rubygems-update-1.3.5/lib/rubygems.rb:68:in `gem'
        from /opt/local/bin/rails:18:in `<main>'
    
  • Robs

    Robs March 25th, 2010 @ 05:50 PM

    I'm having a similar issue. I'm not using rvm. Has anyone been able to get this working? If so, how?

    $ ruby -v
    ruby 1.8.7 (2008-08-11 patchlevel 72) [universal-darwin10.0]
    $ gem list rails
    rails (3.0.0.beta, 2.3.5, 2.3.4, 2.2.2, 1.2.6)
    $ rails 2.3.5 code
    /Library/Ruby/Site/1.8/rubygems.rb:777:in report_activate_error': RubyGem version error: railties(3.0.0.beta not = 2.3.5) (Gem::LoadError)
      from /Library/Ruby/Site/1.8/rubygems.rb:211:inactivate'
      from /Library/Ruby/Site/1.8/rubygems.rb:1056:in gem'
      from /usr/bin/rails:18</code>
    </pre>
    
  • Robs

    Robs March 25th, 2010 @ 05:51 PM

    The italic "2.3.5" part actually had underscores around it, btw...

  • José Valim

    José Valim March 26th, 2010 @ 12:16 AM

    • State changed from “new” to “wontfix”

    Unfortunately won't fix. It's more like a rubygems limitation.

  • klkk

    klkk May 23rd, 2011 @ 02:59 AM

    • Importance changed from “” to “Low”

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile »

<h2 style="font-size: 14px">Tickets have moved to Github</h2>

The new ticket tracker is available at <a href="https://github.com/rails/rails/issues">https://github.com/rails/rails/issues</a>

Pages