Rails 3.03 and Rails 2.38 — can they work together?

Is there a way to install a Rails 2.3.10 app if I have Rails 3.0.3 installed on my machine?

for example i'd like to start my server with ruby script/server instead of rails server.

thx

Answers


Two main ways:

  • Bundler: you can create a Gemfile and use bundler to silo the gems for each of your installations. The drawback to this one is that you'll probably have to use "bundle exec command" whenever you want to run a command for the version of rails you're using, such as spec or cucumber
  • RVM: using RVM you can use not only different versions of Ruby, but also separate gemsets within a version of Ruby. I personally use this method most of the time, creating a gemset called "rails3" and "rails2" (or sometimes I use a gemset for the application) with the relevant gem versions in it. You can have as many gemsets as you want and switch between them. Stick a .rvmrc file in the root of your application, and rvm will switch the version of ruby and your gemset for you automatically.

Need Your Help

SqlBulkCopy ColumnMapping Error

c# sql datatable sqlbulkcopy

My goal is to copy generic tables from one database to another. I would like to have it copy the data as is and it would be fine to either delete whatever is in the table or to add to it with new

MiniProfiler with mvc 3 and ef 4.3

asp.net-mvc entity-framework ef-code-first mvc-mini-profiler

So i've just installed miniprofiler.mvc to my web project and it seems to be working fine.