File tree Expand file tree Collapse file tree 2 files changed +16
-11
lines changed
railties/lib/generators/rails/app/templates Expand file tree Collapse file tree 2 files changed +16
-11
lines changed Original file line number Diff line number Diff line change 1
1
# Edit this Gemfile to bundle your application's dependencies.
2
+ source :gemcutter
3
+
2
4
<% if !dev_or_edge? %>
3
5
gem "rails", "<%= Rails::VERSION::STRING %>"
4
6
<% end -%>
Original file line number Diff line number Diff line change 1
1
# Use Bundler (preferred)
2
- environment = File . expand_path ( '../../vendor/gems/environment' , __FILE__ )
3
- if File . exist? ( "#{ environment } .rb" )
4
- require environment
5
-
6
- # Use 2.x style vendor/rails and RubyGems
7
- else
8
- vendor_rails = File . expand_path ( '../../vendor/rails' , __FILE__ )
9
- if File . exist? ( vendor_rails )
10
- Dir [ "#{ vendor_rails } /*/lib" ] . each { |path | $:. unshift ( path ) }
11
- end
12
-
2
+ begin
3
+ require File . expand_path ( '../../vendor/environment' , __FILE__ )
4
+ rescue LoadError
13
5
require 'rubygems'
6
+ require 'bundler'
7
+ Bundler . setup
8
+
9
+ # To use 2.x style vendor/rails and RubyGems
10
+ #
11
+ # vendor_rails = File.expand_path('../../vendor/rails', __FILE__)
12
+ # if File.exist?(vendor_rails)
13
+ # Dir["#{vendor_rails}/*/lib"].each { |path| $:.unshift(path) }
14
+ # end
15
+ #
16
+ # require 'rubygems'
14
17
end
15
18
16
19
<% unless options[:skip_activerecord] -%>
You can’t perform that action at this time.
0 commit comments