Browse files

[ci skip] updated bin/rails code in Rails Initialization Process guide

  • Loading branch information...
Senthil A
Senthil A committed Mar 24, 2012
1 parent 014498e commit 7feec40b89ada892ca6f107ada27ceedde505d83
Showing with 16 additions and 6 deletions.
  1. +16 −6 guides/source/initialization.textile
@@ -21,14 +21,24 @@ The actual +rails+ command is kept in _bin/rails_:
#!/usr/bin/env ruby
# This file was generated by RubyGems.
# The application 'railties' is installed as part of a gem, and
# this file is here to facilitate running it.
require "rails/cli"
rescue LoadError
railties_path = File.expand_path('../../railties/lib', __FILE__)
require "rails/cli"
require 'rubygems'
version = ">= 0"
if ARGV.first =~ /^_(.*)_$/ and Gem::Version.correct? $1 then
version = $1
gem 'railties', version
load Gem.bin_path('railties', 'rails', version)
This file will attempt to load +rails/cli+. If it cannot find it then +railties/lib+ is added to the load path (+$:+) before retrying.

0 comments on commit 7feec40

Please sign in to comment.