forked from moonproject/globalize
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Appraisals
49 lines (42 loc) · 1.15 KB
/
Appraisals
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
# frozen_string_literal: true
RAILS_VERSIONS = %w[
4.2.11.3
5.1.7
5.2.5
6.0.3.6
6.1.3.1
7.0.1
]
RAILS_VERSIONS.each do |version|
appraise "rails_#{version}" do
gem 'activemodel', version
gem 'activerecord', version
if version =~ /^4/
gem 'sqlite3', '~> 1.3.6', platforms: [:ruby, :rbx]
elsif version =~ /^5/
gem 'sqlite3', '~> 1.3', '>= 1.3.6', platforms: [:ruby, :rbx]
else
gem 'sqlite3', '~> 1.4', platforms: [:ruby, :rbx]
end
if !ENV['CI'] || %w(postgres postgresql).include?(ENV['DB'])
group :postgres, :postgresql do
if version =~ /^4/
gem 'pg', '< 1.0', platforms: [:ruby, :rbx]
else
gem 'pg', '~> 1.1', platforms: [:ruby, :rbx]
end
end
end
platforms :jruby do
if !ENV['CI'] || ENV['DB'] == 'sqlite3'
gem 'activerecord-jdbcsqlite3-adapter', '~> 1'
end
if !ENV['CI'] || ENV['DB'] == 'mysql'
gem 'activerecord-jdbcmysql-adapter', '~> 1'
end
if !ENV['CI'] || %w(postgres postgresql).include?(ENV['DB'])
gem 'activerecord-jdbcpostgresql-adapter', '~> 1'
end
end
end
end