Project

General

Profile

Feature #5638 » bundler-r8745.diff

Toshi MARUYAMA, 2012-02-01 09:28

View differences:

Gemfile
1
source :rubygems
2
source :rubyforge
3
source :gemcutter
4

  
5
gem 'bundler', '~> 1.0.0'
6
gem 'rails', '2.3.14'
7
gem 'rack' , '~> 1.1.1'
8
gem 'i18n', '>= 0.4.2'
9
gem 'rubytree', '0.5.2', :require => 'tree'
10
# gem 'coderay', '~> 0.9.7'
11
gem 'coderay'
12

  
13
# Please uncomment lines for your databases.
14
# Alternatively you may want to add these lines to specific groups below.
15
# gem 'sqlite3-ruby', :require => 'sqlite3'  # for SQLite 3
16
# gem 'mysql'                                #     MySQL
17
# gem 'pg'                                   #     PostgreSQL
18
gem 'pg'
19

  
20
group :development do
21
end
22

  
23
group :production do
24
end
25

  
26
group :test do
27
  gem 'shoulda'
28
  gem 'mocha'
29
  gem 'edavis10-object_daddy', :require => 'object_daddy'
30
end
31

  
32
# Load plugins Gemfiles
33
Dir.glob(File.join(File.dirname(__FILE__), %w(vendor plugins * Gemfile))) do |file|
34
  puts "Loading #{file} ..."
35
  instance_eval File.read(file)
36
end
config/boot.rb
41 41
  class Boot
42 42
    def run
43 43
      load_initializer
44

  
45
      Rails::Initializer.class_eval do
46
        def load_gems
47
          @bundler_loaded ||= Bundler.require :default, Rails.env
48
        end
49
      end
50

  
44 51
      Rails::Initializer.run(:set_load_path)
45 52
    end
46 53
  end
config/environment.rb
54 54
  # It will automatically turn deliveries on
55 55
  config.action_mailer.perform_deliveries = false
56 56

  
57
  config.gem 'coderay', :version => '~>1.0.0'
58

  
59 57
  # Load any local configuration that is kept out of source control
60 58
  # (e.g. gems, patches).
61 59
  if File.exists?(File.join(File.dirname(__FILE__), 'additional_environment.rb'))
config/preinitializer.rb
1
begin
2
  require "rubygems"
3
  require "bundler"
4
rescue LoadError
5
  raise "Could not load the bundler gem. Install it with `gem install bundler`."
6
end
7

  
8
if Gem::Version.new(Bundler::VERSION) <= Gem::Version.new("0.9.25")
9
  raise RuntimeError, "Your bundler version is too old for Rails 2.3." +
10
   "Run `gem install bundler` to upgrade."
11
end
12

  
13
begin
14
  # Set up load paths for all bundled gems
15
  ENV["BUNDLE_GEMFILE"] = File.expand_path("../../Gemfile", __FILE__)
16
  Bundler.setup
17
rescue Bundler::GemNotFound
18
  raise RuntimeError, "Bundler couldn't find some gems." +
19
    "Did you run `bundle install`?"
20
end
Gemfile
2 2
source :rubyforge
3 3
source :gemcutter
4 4

  
5
gem "ruby-openid"
5 6
gem 'bundler', '~> 1.0.0'
6 7
gem 'rails', '2.3.14'
7 8
gem 'rack' , '~> 1.1.1'
......
10 11
# gem 'coderay', '~> 0.9.7'
11 12
gem 'coderay'
12 13

  
13
# Please uncomment lines for your databases.
14
# Alternatively you may want to add these lines to specific groups below.
15
# gem 'sqlite3-ruby', :require => 'sqlite3'  # for SQLite 3
16
# gem 'mysql'                                #     MySQL
17
# gem 'pg'                                   #     PostgreSQL
18
gem 'pg'
19

  
20 14
group :development do
21 15
end
22 16

  
......
24 18
end
25 19

  
26 20
group :test do
27
  gem 'shoulda'
21
  gem 'shoulda', '~> 2.10.3'
28 22
  gem 'mocha'
29 23
  gem 'edavis10-object_daddy', :require => 'object_daddy'
30 24
end
31 25

  
26

  
27
# Use the commented pure ruby gems, if you have not the needed prerequisites on
28
# board to compile the native ones.  Note, that their use is discouraged, since
29
# their integration is propbably not that well tested and their are slower in
30
# orders of magnitude compared to their native counterparts. You have been
31
# warned.
32
#
33
platforms :mri do
34
  group :mysql do
35
    gem "mysql"
36
    #   gem "ruby-mysql"
37
  end
38

  
39
  group :mysql2 do
40
    gem "mysql2"
41
  end
42

  
43
  group :postgres do
44
    gem "pg", "~> 0.9.0"
45
    #   gem "postgres-pr"
46
  end
47

  
48
  group :sqlite do
49
    gem "sqlite3-ruby", "< 1.3", :require => "sqlite3"
50
    #   please tell me, if you are fond of a pure ruby sqlite3 binding
51
  end
52
end
53

  
54
platforms :jruby do
55
  gem "jruby-openssl"
56

  
57
  group :mysql do
58
    gem "activerecord-jdbcmysql-adapter"
59
  end
60

  
61
  group :postgres do
62
    gem "activerecord-jdbcpostgresql-adapter"
63
  end
64

  
65
  group :sqlite do
66
    gem "activerecord-jdbcsqlite3-adapter"
67
  end
68
end
69

  
32 70
# Load plugins Gemfiles
33 71
Dir.glob(File.join(File.dirname(__FILE__), %w(vendor plugins * Gemfile))) do |file|
34 72
  puts "Loading #{file} ..."
config/boot.rb
42 42
    def run
43 43
      load_initializer
44 44

  
45
      # This block was added for bundler support while following setup
46
      # instructions from http://gembundler.com/rails23.html
45 47
      Rails::Initializer.class_eval do
46 48
        def load_gems
47 49
          @bundler_loaded ||= Bundler.require :default, Rails.env
config/environments/test.rb
23 23

  
24 24
# Skip protect_from_forgery in requests http://m.onkey.org/2007/9/28/csrf-protection-for-your-existing-rails-application
25 25
config.action_controller.allow_forgery_protection  = false
26

  
27
config.gem "shoulda", :version => "~> 2.10.3"
28
config.gem "edavis10-object_daddy", :lib => "object_daddy"
29
config.gem "mocha"
Gemfile
2 2
source :rubyforge
3 3
source :gemcutter
4 4

  
5
gem "ruby-openid"
6 5
gem 'bundler', '~> 1.0.0'
7 6
gem 'rails', '2.3.14'
8 7
gem 'rack' , '~> 1.1.1'
......
23 22
  gem 'edavis10-object_daddy', :require => 'object_daddy'
24 23
end
25 24

  
25
group :openid do
26
  gem "ruby-openid", '~> 2.1.4', :require => 'openid'
27
end
26 28

  
27 29
# Use the commented pure ruby gems, if you have not the needed prerequisites on
28 30
# board to compile the native ones.  Note, that their use is discouraged, since
Gemfile
39 39
  end
40 40

  
41 41
  group :mysql2 do
42
    gem "mysql2"
42
    gem "mysql2", "~> 0.2.7"
43 43
  end
44 44

  
45 45
  group :postgres do
Gemfile
71 71

  
72 72
# Load plugins Gemfiles
73 73
Dir.glob(File.join(File.dirname(__FILE__), %w(vendor plugins * Gemfile))) do |file|
74
  puts "Loading #{file} ..."
74
  puts "Loading #{file} ..." if $DEBUG # `ruby -d` or `bundle -v`
75 75
  instance_eval File.read(file)
76 76
end
Gemfile
46 46
    gem "pg", "~> 0.9.0"
47 47
    #   gem "postgres-pr"
48 48
  end
49
end
49 50

  
51
platforms :mri_18 do
50 52
  group :sqlite do
51 53
    gem "sqlite3-ruby", "< 1.3", :require => "sqlite3"
52
    #   please tell me, if you are fond of a pure ruby sqlite3 binding
54
  end
55
end
56

  
57
platforms :mri_19 do
58
  group :sqlite do
59
    gem "sqlite3"
53 60
  end
54 61
end
55 62

  
Gemfile
32 32
# orders of magnitude compared to their native counterparts. You have been
33 33
# warned.
34 34
#
35
platforms :mri do
35
platforms :mri, :mingw do
36 36
  group :mysql do
37 37
    gem "mysql"
38 38
    #   gem "ruby-mysql"
39 39
  end
40 40

  
41
  group :mysql2 do
42
    gem "mysql2", "~> 0.2.7"
43
  end
44

  
45 41
  group :postgres do
46 42
    gem "pg", "~> 0.9.0"
47 43
    #   gem "postgres-pr"
48 44
  end
49 45
end
50 46

  
51
platforms :mri_18 do
47
platforms :mri_18, :mingw_18 do
52 48
  group :sqlite do
53 49
    gem "sqlite3-ruby", "< 1.3", :require => "sqlite3"
54 50
  end
55 51
end
56 52

  
57 53
platforms :mri_19 do
54
  ## Add Windows support
55
  ## https://github.com/brianmario/mysql2/issues/8
56
  ## Getting mysql2 gem to work with Ruby on Rails 3.0 and Windows 7 64bit
57
  ## http://paul-wong-jr.blogspot.com/2011/06/getting-mysql2-gem-to-work-with-ruby-on.html
58
  group :mysql2 do
59
    gem "mysql2", "~> 0.2.7"
60
  end
61

  
58 62
  group :sqlite do
59 63
    gem "sqlite3"
60 64
  end
Gemfile
80 80
  end
81 81
end
82 82

  
83
# Load a "local" Gemfile
84
gemfile_local = File.join(File.dirname(__FILE__), "Gemfile.local")
85
if File.readable?(gemfile_local)
86
  puts "Loading #{gemfile_local} ..." if $DEBUG
87
  instance_eval(File.read(gemfile_local))
88
end
89

  
83 90
# Load plugins Gemfiles
84 91
Dir.glob(File.join(File.dirname(__FILE__), %w(vendor plugins * Gemfile))) do |file|
85 92
  puts "Loading #{file} ..." if $DEBUG # `ruby -d` or `bundle -v`
Gemfile
10 10
# gem 'coderay', '~> 0.9.7'
11 11
gem 'coderay'
12 12

  
13
gem "fastercsv", "~> 1.5.0", :platforms => [:mri_18, :jruby, :mingw_18]
14

  
13 15
group :development do
14 16
end
15 17

  
Gemfile
28 28
  gem "ruby-openid", '~> 2.1.4', :require => 'openid'
29 29
end
30 30

  
31
group :rmagick do
32
  platforms :mri_18 do gem "rmagick", "~> 1.15.17" end
33

  
34
  ## You cannot specify the same gem twice with different version requirements.
35
  ## You specified: rmagick (~> 1.15.17) and rmagick (>= 0)
36
  ## https://github.com/carlhuda/bundler/issues/751
37
  # platforms :mri_19 do gem "rmagick" end
38

  
39
  platforms :jruby do gem "rmagick4j" end
40
end
41

  
31 42
# Use the commented pure ruby gems, if you have not the needed prerequisites on
32 43
# board to compile the native ones.  Note, that their use is discouraged, since
33 44
# their integration is propbably not that well tested and their are slower in
Gemfile
24 24
  gem 'edavis10-object_daddy', :require => 'object_daddy'
25 25
end
26 26

  
27
group :ldap do
28
  gem "net-ldap", '~> 0.2.2'
29
end
30

  
27 31
group :openid do
28 32
  gem "ruby-openid", '~> 2.1.4', :require => 'openid'
29 33
end
(10-10/12)