I have been testing out Rails 3 beta4, but want to create a test
application in Rails 2.3.8.
So, i installed the Rails version that i wanted, sudo gem install rails
-v=2.3.8. Now when i try to create my application, using rails myTestApp
-v=2.3.8, I get the rails help screen. Looking over it, I can’t seem to
find the option to specify the version of rails that I want to target.
rails new APP_PATH [options]
-G, [–skip-git] # Skip Git ignores and keeps
-b, [–builder=BUILDER] # Path to an application builder (can be a
filesystem path or URL)
-r, [–ruby=PATH] # Path to the Ruby binary of your choice
[–edge] # Setup the application with Gemfile
pointing to Rails repository
[–dev] # Setup the application with Gemfile
pointing to your Rails checkout
[–skip-gemfile] # Don’t create a Gemfile
-d, [–database=DATABASE] # Preconfigure for selected database
# Default: sqlite3
-O, [–skip-activerecord] # Skip ActiveRecord files
-J, [–skip-prototype] # Skip Prototype files
-T, [–skip-testunit] # Skip TestUnit files
-m, [–template=TEMPLATE] # Path to an application template (can be a
filesystem path or URL).
-s, [–skip] # Skip files that already exist
-f, [–force] # Overwrite files that already exist
-p, [–pretend] # Run but do not make any changes
-q, [–quiet] # Supress status output
-v, [–version] # Show Rails version number and quit
-h, [–help] # Show this help message and quit
The ‘rails new’ command creates a new Rails application with a
directory structure and configuration at the path you specify.
rails new ~/Code/Ruby/weblog
This generates a skeletal Rails installation in ~/Code/Ruby/weblog. See the README in the newly created application to get going.