arel_extensions 1.2.17 → 1.2.25
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ruby.yml +102 -0
- data/Gemfile +10 -10
- data/Rakefile +4 -4
- data/arel_extensions.gemspec +1 -1
- data/gemfiles/rails3.gemfile +9 -9
- data/gemfiles/rails4.gemfile +13 -13
- data/gemfiles/rails5_0.gemfile +13 -13
- data/gemfiles/rails5_1_4.gemfile +13 -13
- data/gemfiles/rails5_2.gemfile +13 -13
- data/gemfiles/rails6.gemfile +13 -13
- data/gemfiles/rails6_1.gemfile +30 -0
- data/gemspecs/arel_extensions-v1.gemspec +28 -0
- data/{gemspec_v2 → gemspecs}/arel_extensions-v2.gemspec +0 -0
- data/generate_gems.sh +4 -3
- data/lib/arel_extensions.rb +23 -5
- data/lib/arel_extensions/attributes.rb +0 -0
- data/lib/arel_extensions/boolean_functions.rb +3 -7
- data/lib/arel_extensions/common_sql_functions.rb +0 -2
- data/lib/arel_extensions/comparators.rb +11 -14
- data/lib/arel_extensions/date_duration.rb +4 -5
- data/lib/arel_extensions/insert_manager.rb +16 -17
- data/lib/arel_extensions/math.rb +8 -9
- data/lib/arel_extensions/math_functions.rb +22 -20
- data/lib/arel_extensions/nodes/abs.rb +0 -1
- data/lib/arel_extensions/nodes/aggregate_function.rb +0 -1
- data/lib/arel_extensions/nodes/blank.rb +0 -1
- data/lib/arel_extensions/nodes/case.rb +3 -4
- data/lib/arel_extensions/nodes/cast.rb +0 -1
- data/lib/arel_extensions/nodes/ceil.rb +1 -1
- data/lib/arel_extensions/nodes/change_case.rb +0 -0
- data/lib/arel_extensions/nodes/coalesce.rb +0 -1
- data/lib/arel_extensions/nodes/collate.rb +0 -1
- data/lib/arel_extensions/nodes/concat.rb +2 -4
- data/lib/arel_extensions/nodes/date_diff.rb +4 -5
- data/lib/arel_extensions/nodes/duration.rb +0 -1
- data/lib/arel_extensions/nodes/find_in_set.rb +0 -1
- data/lib/arel_extensions/nodes/floor.rb +1 -1
- data/lib/arel_extensions/nodes/format.rb +1 -0
- data/lib/arel_extensions/nodes/formatted_number.rb +0 -1
- data/lib/arel_extensions/nodes/function.rb +8 -5
- data/lib/arel_extensions/nodes/is_null.rb +0 -0
- data/lib/arel_extensions/nodes/json.rb +0 -6
- data/lib/arel_extensions/nodes/length.rb +5 -0
- data/lib/arel_extensions/nodes/levenshtein_distance.rb +0 -0
- data/lib/arel_extensions/nodes/locate.rb +0 -1
- data/lib/arel_extensions/nodes/log10.rb +1 -2
- data/lib/arel_extensions/nodes/matches.rb +0 -2
- data/lib/arel_extensions/nodes/md5.rb +0 -1
- data/lib/arel_extensions/nodes/power.rb +0 -1
- data/lib/arel_extensions/nodes/rand.rb +0 -1
- data/lib/arel_extensions/nodes/repeat.rb +0 -2
- data/lib/arel_extensions/nodes/replace.rb +0 -2
- data/lib/arel_extensions/nodes/round.rb +0 -1
- data/lib/arel_extensions/nodes/soundex.rb +0 -1
- data/lib/arel_extensions/nodes/std.rb +4 -5
- data/lib/arel_extensions/nodes/substring.rb +0 -1
- data/lib/arel_extensions/nodes/sum.rb +0 -0
- data/lib/arel_extensions/nodes/then.rb +0 -0
- data/lib/arel_extensions/nodes/trim.rb +0 -2
- data/lib/arel_extensions/nodes/union.rb +0 -2
- data/lib/arel_extensions/nodes/union_all.rb +0 -2
- data/lib/arel_extensions/nodes/wday.rb +0 -4
- data/lib/arel_extensions/null_functions.rb +3 -5
- data/lib/arel_extensions/predications.rb +2 -3
- data/lib/arel_extensions/railtie.rb +5 -5
- data/lib/arel_extensions/set_functions.rb +0 -2
- data/lib/arel_extensions/string_functions.rb +30 -23
- data/lib/arel_extensions/tasks.rb +1 -1
- data/lib/arel_extensions/version.rb +1 -1
- data/lib/arel_extensions/visitors.rb +68 -60
- data/lib/arel_extensions/visitors/convert_format.rb +37 -0
- data/lib/arel_extensions/visitors/ibm_db.rb +4 -11
- data/lib/arel_extensions/visitors/mssql.rb +50 -45
- data/lib/arel_extensions/visitors/mysql.rb +63 -65
- data/lib/arel_extensions/visitors/oracle.rb +50 -57
- data/lib/arel_extensions/visitors/oracle12.rb +1 -14
- data/lib/arel_extensions/visitors/postgresql.rb +39 -34
- data/lib/arel_extensions/visitors/sqlite.rb +23 -18
- data/lib/arel_extensions/visitors/to_sql.rb +58 -48
- data/test/arelx_test_helper.rb +0 -2
- data/test/database.yml +2 -0
- data/test/real_db_test.rb +26 -41
- data/test/support/fake_record.rb +1 -1
- data/test/test_comparators.rb +0 -4
- data/test/visitors/test_bulk_insert_oracle.rb +0 -1
- data/test/visitors/test_bulk_insert_sqlite.rb +0 -2
- data/test/visitors/test_oracle.rb +1 -2
- data/test/visitors/test_to_sql.rb +16 -25
- data/test/with_ar/all_agnostic_test.rb +140 -139
- data/test/with_ar/insert_agnostic_test.rb +0 -2
- data/test/with_ar/test_bulk_sqlite.rb +0 -4
- data/test/with_ar/test_math_sqlite.rb +4 -8
- data/test/with_ar/test_string_mysql.rb +1 -5
- data/test/with_ar/test_string_sqlite.rb +1 -5
- data/version_v1.rb +1 -1
- data/version_v2.rb +1 -1
- metadata +8 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 006465d41dbb691f2048bd0ffc2aaf3d2f1f48f508955f50774ee9c0413ccfa5
|
4
|
+
data.tar.gz: 47c61ff636e5fd8c4eb0f470facd661406c4bdca590037a1af5ba87e02ca415e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f6fb93194f8d9841380ba59e1fd72e0afa8bc0c84809d44e6af6b1282ce04bf1933900aafa6715cbdbf074cd6ba0585698aadc1678c80c1cbfdacc85a04472c3
|
7
|
+
data.tar.gz: a4ac1afdba08edb577f182e9e7d7236a5f87ce741ef63979b95c24ac2562fee76576964dc3b58c54a052952046e51c2ae5a9225d2b91c830eecba3c3b372da52
|
@@ -0,0 +1,102 @@
|
|
1
|
+
# This workflow uses actions that are not certified by GitHub.
|
2
|
+
# They are provided by a third-party and are governed by
|
3
|
+
# separate terms of service, privacy policy, and support
|
4
|
+
# documentation.
|
5
|
+
# This workflow will download a prebuilt Ruby version, install dependencies and run tests with Rake
|
6
|
+
# For more information see: https://github.com/marketplace/actions/setup-ruby-jruby-and-truffleruby
|
7
|
+
|
8
|
+
name: Ruby
|
9
|
+
|
10
|
+
on:
|
11
|
+
push:
|
12
|
+
branches: [ master ]
|
13
|
+
pull_request:
|
14
|
+
branches: [ master ]
|
15
|
+
|
16
|
+
jobs:
|
17
|
+
test:
|
18
|
+
|
19
|
+
runs-on: ubuntu-latest
|
20
|
+
|
21
|
+
services:
|
22
|
+
postgres:
|
23
|
+
image: postgres:11.6-alpine
|
24
|
+
env:
|
25
|
+
POSTGRES_DB: arext_test
|
26
|
+
ports:
|
27
|
+
- 5432:5432
|
28
|
+
# needed because the postgres container does not provide a healthcheck
|
29
|
+
options: >-
|
30
|
+
--health-cmd "pg_isready -d arext_test -U postgres -p 5432"
|
31
|
+
--health-interval 10s
|
32
|
+
--health-timeout 5s
|
33
|
+
--health-retries 5
|
34
|
+
mysql:
|
35
|
+
image: mysql:5.7
|
36
|
+
env:
|
37
|
+
MYSQL_ALLOW_EMPTY_PASSWORD: true
|
38
|
+
MYSQL_USERNAME: travis
|
39
|
+
MYSQL_DATABASE: arext_test
|
40
|
+
ports:
|
41
|
+
- 3306:3306
|
42
|
+
options: >-
|
43
|
+
--health-cmd="mysqladmin ping"
|
44
|
+
--health-interval=10s
|
45
|
+
--health-timeout=5s
|
46
|
+
--health-retries=3
|
47
|
+
|
48
|
+
strategy:
|
49
|
+
matrix:
|
50
|
+
ruby-version:
|
51
|
+
- 3.0.0-preview1
|
52
|
+
- 2.7
|
53
|
+
- 2.5
|
54
|
+
- 2.3
|
55
|
+
rails-version:
|
56
|
+
- 6_1
|
57
|
+
- 6
|
58
|
+
- 5_2
|
59
|
+
exclude:
|
60
|
+
- ruby-version: 2.3
|
61
|
+
rails-version: 6_1
|
62
|
+
- ruby-version: 2.3
|
63
|
+
rails-version: 6
|
64
|
+
- ruby-version: 3.0.0-preview1
|
65
|
+
rails-version: 5.2
|
66
|
+
continue-on-error: ${{ true }}
|
67
|
+
|
68
|
+
steps:
|
69
|
+
- uses: actions/checkout@v2
|
70
|
+
- name: Set up Ruby
|
71
|
+
# To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
|
72
|
+
# change this to (see https://github.com/ruby/setup-ruby#versioning):
|
73
|
+
# uses: ruby/setup-ruby@v1
|
74
|
+
uses: ruby/setup-ruby@21351ecc0a7c196081abca5dc55b08f085efe09a
|
75
|
+
with:
|
76
|
+
ruby-version: ${{ matrix.ruby-version }}
|
77
|
+
- name: Setup gemspec
|
78
|
+
if: ${{ matrix.rails-version == '6_1' || matrix.rails-version == '6' }}
|
79
|
+
run: cp ./gemspecs/arel_extensions-v2.gemspec ./arel_extensions.gemspec
|
80
|
+
- name: Install dependencies
|
81
|
+
run: |
|
82
|
+
export BUNDLE_GEMFILE=gemfiles/rails${{ matrix.rails-version }}.gemfile
|
83
|
+
bundle install
|
84
|
+
- name: Run test to_sql
|
85
|
+
run: rake test:to_sql
|
86
|
+
- name: Run test Postgres
|
87
|
+
env:
|
88
|
+
PGHOST: localhost
|
89
|
+
PGUSER: postgres
|
90
|
+
run: rake test:postgresql
|
91
|
+
- name: Run test MySql
|
92
|
+
env:
|
93
|
+
DB_CONNECTION: mysql
|
94
|
+
DB_HOST: 127.0.0.1
|
95
|
+
DB_PORT: 3306
|
96
|
+
DB_DATABASE: arext_test
|
97
|
+
DB_USERNAME: travis
|
98
|
+
run: |
|
99
|
+
sudo apt-get install -y mysql-client
|
100
|
+
mysql --host 127.0.0.1 --port 3306 -uroot -e 'create user travis;'
|
101
|
+
mysql --host 127.0.0.1 --port 3306 -uroot -e 'GRANT ALL PRIVILEGES ON arext_test.* TO travis;'
|
102
|
+
rake test:mysql
|
data/Gemfile
CHANGED
@@ -3,19 +3,19 @@ source "https://rubygems.org"
|
|
3
3
|
gemspec
|
4
4
|
|
5
5
|
group :development, :test do
|
6
|
-
gem "sqlite3", '<= 1.3.13', :
|
7
|
-
gem "mysql2", '0.4.10', :
|
8
|
-
gem "pg", '< 1', :
|
6
|
+
gem "sqlite3", '<= 1.3.13', platforms: [:mri, :mswin, :x64_mingw, :mingw]
|
7
|
+
gem "mysql2", '0.4.10', platforms: [:mri, :mswin, :x64_mingw, :mingw]
|
8
|
+
gem "pg", '< 1', platforms: [:mri, :mingw, :x64_mingw, :mswin]
|
9
9
|
|
10
|
-
gem "jdbc-sqlite3", :
|
11
|
-
gem "activerecord-jdbcsqlite3-adapter", :
|
12
|
-
gem "activerecord-jdbcmysql-adapter", :
|
13
|
-
gem "activerecord-jdbcpostgresql-adapter", :
|
10
|
+
gem "jdbc-sqlite3", platforms: :jruby
|
11
|
+
gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
|
12
|
+
gem "activerecord-jdbcmysql-adapter", platforms: :jruby
|
13
|
+
gem "activerecord-jdbcpostgresql-adapter", platforms: :jruby
|
14
14
|
|
15
|
-
gem "tiny_tds", '~> 1.3.0'
|
16
|
-
gem "activerecord-sqlserver-adapter", '~> 4.2.0', :
|
15
|
+
gem "tiny_tds", '~> 1.3.0',require: false, platforms: [:mri,:mingw, :x64_mingw, :mswin]
|
16
|
+
gem "activerecord-sqlserver-adapter", '~> 4.2.0', platforms: [:mri, :mingw, :x64_mingw, :mswin]
|
17
17
|
|
18
|
-
gem 'ruby-oci8', :
|
18
|
+
gem 'ruby-oci8', platforms: [:mri, :mswin, :x64_mingw, :mingw]
|
19
19
|
gem 'activerecord-oracle_enhanced-adapter', '~> 1.6.0'
|
20
20
|
|
21
21
|
gem 'activesupport', '~> 4.0'
|
data/Rakefile
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
require 'bundler'
|
2
|
-
Bundler::GemHelper.install_tasks :
|
2
|
+
Bundler::GemHelper.install_tasks name: "arel_extensions"
|
3
3
|
|
4
4
|
require 'rake/testtask'
|
5
5
|
|
6
6
|
desc "Default Task"
|
7
|
-
task default: [
|
7
|
+
task default: [:test]
|
8
8
|
|
9
9
|
Rake::TestTask.new(:test) do |t|
|
10
10
|
t.libs << 'lib'
|
@@ -38,8 +38,8 @@ end
|
|
38
38
|
end
|
39
39
|
|
40
40
|
namespace adapter do
|
41
|
-
task :
|
42
|
-
task :
|
41
|
+
task test: "test_#{adapter}"
|
42
|
+
task isolated_test: "isolated_test_#{adapter}"
|
43
43
|
|
44
44
|
# Set the connection environment for the adapter
|
45
45
|
task(:env) { ENV['DB'] = adapter }
|
data/arel_extensions.gemspec
CHANGED
data/gemfiles/rails3.gemfile
CHANGED
@@ -3,18 +3,18 @@ source "https://rubygems.org"
|
|
3
3
|
gem 'arel', '~> 3.0' # too old...
|
4
4
|
|
5
5
|
group :development, :test do
|
6
|
-
gem "sqlite3", '<= 1.3.13', :
|
7
|
-
gem "mysql2", '0.4.10', :
|
8
|
-
gem "activerecord-mysql2-adapter", :
|
9
|
-
gem "pg", :
|
6
|
+
gem "sqlite3", '<= 1.3.13', platform: [:ruby, :mswin, :mingw]
|
7
|
+
gem "mysql2", '0.4.10', platform: [:ruby, :mswin, :mingw]
|
8
|
+
gem "activerecord-mysql2-adapter", platform: [:ruby, :mswin, :mingw]
|
9
|
+
gem "pg", platform: [:ruby, :mswin, :mingw]
|
10
10
|
# for JRuby
|
11
|
-
gem "jdbc-sqlite3", :
|
12
|
-
gem "activerecord-jdbcsqlite3-adapter", :
|
13
|
-
gem "activerecord-jdbcmysql-adapter", :
|
14
|
-
gem "activerecord-jdbcpostgresql-adapter", :
|
11
|
+
gem "jdbc-sqlite3", platform: :jruby
|
12
|
+
gem "activerecord-jdbcsqlite3-adapter", platform: :jruby
|
13
|
+
gem "activerecord-jdbcmysql-adapter", platform: :jruby
|
14
|
+
gem "activerecord-jdbcpostgresql-adapter", platform: :jruby
|
15
15
|
gem 'activesupport', '~> 3.2'
|
16
16
|
gem 'activemodel', '~> 3.2'
|
17
17
|
gem 'activerecord', '~> 3.2'
|
18
18
|
end
|
19
19
|
|
20
|
-
gemspec :
|
20
|
+
gemspec path: "../"
|
data/gemfiles/rails4.gemfile
CHANGED
@@ -7,23 +7,23 @@ group :development, :test do
|
|
7
7
|
gem 'activemodel', '~> 4.0'
|
8
8
|
gem 'activerecord', '~> 4.0'
|
9
9
|
|
10
|
-
gem "sqlite3", '<= 1.3.13', :
|
11
|
-
gem "mysql2", '0.4.10', :
|
12
|
-
gem "pg",'< 1.0.0', :
|
10
|
+
gem "sqlite3", '<= 1.3.13', platforms: [:mri, :mswin, :mingw]
|
11
|
+
gem "mysql2", '0.4.10', platforms: [:mri, :mswin, :mingw]
|
12
|
+
gem "pg",'< 1.0.0', platforms: [:mri, :mingw]
|
13
13
|
|
14
|
-
gem "tiny_tds", :
|
15
|
-
gem "activerecord-sqlserver-adapter", '~> 4.2.0', :
|
14
|
+
gem "tiny_tds", platforms: [:mri, :mingw, :mswin] if RUBY_PLATFORM =~ /windows/
|
15
|
+
gem "activerecord-sqlserver-adapter", '~> 4.2.0', platforms: [:mri, :mingw, :mswin] if RUBY_PLATFORM =~ /windows/
|
16
16
|
|
17
|
-
gem 'ruby-oci8', :
|
17
|
+
gem 'ruby-oci8', platforms: [:mri, :mswin, :mingw] if ENV.has_key? 'ORACLE_HOME'
|
18
18
|
gem 'activerecord-oracle_enhanced-adapter', '~> 1.6.0' if ENV.has_key? 'ORACLE_HOME'
|
19
19
|
|
20
20
|
# for JRuby
|
21
|
-
gem 'activerecord-jdbc-adapter', '~> 1.3'
|
22
|
-
gem "jdbc-sqlite3", :
|
23
|
-
gem "activerecord-jdbcsqlite3-adapter", :
|
24
|
-
gem "activerecord-jdbcmysql-adapter", :
|
25
|
-
gem "activerecord-jdbcpostgresql-adapter", :
|
26
|
-
gem "activerecord-jdbcmssql-adapter", :
|
21
|
+
gem 'activerecord-jdbc-adapter', '~> 1.3',platforms: :jruby
|
22
|
+
gem "jdbc-sqlite3", platforms: :jruby
|
23
|
+
gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
|
24
|
+
gem "activerecord-jdbcmysql-adapter", platforms: :jruby
|
25
|
+
gem "activerecord-jdbcpostgresql-adapter", platforms: :jruby
|
26
|
+
gem "activerecord-jdbcmssql-adapter", platforms: :jruby
|
27
27
|
end
|
28
28
|
|
29
|
-
gemspec :
|
29
|
+
gemspec path: "../"
|
data/gemfiles/rails5_0.gemfile
CHANGED
@@ -7,23 +7,23 @@ group :development, :test do
|
|
7
7
|
gem 'activemodel', '~> 5.0'
|
8
8
|
gem 'activerecord', '5.0.6'
|
9
9
|
|
10
|
-
gem "sqlite3", '<= 1.3.13', :
|
11
|
-
gem "mysql2", '0.4.10', :
|
12
|
-
gem "pg",'< 1.0.0', :
|
10
|
+
gem "sqlite3", '<= 1.3.13', platforms: [:mri, :mswin, :mingw]
|
11
|
+
gem "mysql2", '0.4.10', platforms: [:mri, :mswin, :mingw]
|
12
|
+
gem "pg",'< 1.0.0', platforms: [:mri, :mingw]
|
13
13
|
|
14
|
-
gem "tiny_tds", :
|
15
|
-
#gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw]
|
14
|
+
gem "tiny_tds", platforms: [:mri, :mingw] if RUBY_PLATFORM =~ /windows/
|
15
|
+
# gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw]
|
16
16
|
|
17
|
-
gem 'ruby-oci8', :
|
17
|
+
gem 'ruby-oci8', platforms: [:mri, :mswin, :mingw] if ENV.has_key? 'ORACLE_HOME'
|
18
18
|
gem 'activerecord-oracle_enhanced-adapter', '~> 1.7' if ENV.has_key? 'ORACLE_HOME'
|
19
19
|
|
20
20
|
# for JRuby
|
21
|
-
gem 'activerecord-jdbc-adapter', :
|
22
|
-
gem "jdbc-sqlite3", :
|
23
|
-
gem "activerecord-jdbcsqlite3-adapter", :
|
24
|
-
gem "activerecord-jdbcmysql-adapter", :
|
25
|
-
gem "activerecord-jdbcpostgresql-adapter", :
|
26
|
-
gem "activerecord-jdbcmssql-adapter", :
|
21
|
+
gem 'activerecord-jdbc-adapter', github: 'jruby/activerecord-jdbc-adapter', tag: 'v50.0', platforms: :jruby
|
22
|
+
gem "jdbc-sqlite3", platforms: :jruby
|
23
|
+
gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
|
24
|
+
gem "activerecord-jdbcmysql-adapter", platforms: :jruby
|
25
|
+
gem "activerecord-jdbcpostgresql-adapter", platforms: :jruby
|
26
|
+
gem "activerecord-jdbcmssql-adapter", platforms: :jruby
|
27
27
|
end
|
28
28
|
|
29
|
-
gemspec :
|
29
|
+
gemspec path: "../"
|
data/gemfiles/rails5_1_4.gemfile
CHANGED
@@ -8,23 +8,23 @@ group :development, :test do
|
|
8
8
|
gem 'activemodel', '5.1.4'
|
9
9
|
gem 'activerecord', '5.1.4'
|
10
10
|
|
11
|
-
gem "sqlite3", '<= 1.3.13', :
|
12
|
-
gem "mysql2", '0.4.10', :
|
13
|
-
gem "pg",'< 1.0.0', :
|
11
|
+
gem "sqlite3", '<= 1.3.13', platforms: [:mri, :mswin, :mingw]
|
12
|
+
gem "mysql2", '0.4.10', platforms: [:mri, :mswin, :mingw]
|
13
|
+
gem "pg",'< 1.0.0', platforms: [:mri, :mingw]
|
14
14
|
|
15
|
-
gem "tiny_tds", :
|
16
|
-
#gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw]
|
15
|
+
gem "tiny_tds", platforms: [:mri, :mingw] if RUBY_PLATFORM =~ /windows/
|
16
|
+
# gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw]
|
17
17
|
|
18
|
-
gem 'ruby-oci8', :
|
18
|
+
gem 'ruby-oci8', platforms: [:mri, :mswin, :mingw] if ENV.has_key? 'ORACLE_HOME'
|
19
19
|
gem 'activerecord-oracle_enhanced-adapter', '~> 1.8' if ENV.has_key? 'ORACLE_HOME'
|
20
20
|
|
21
21
|
# for JRuby
|
22
|
-
gem 'activerecord-jdbc-adapter', :
|
23
|
-
gem "jdbc-sqlite3", :
|
24
|
-
gem "activerecord-jdbcsqlite3-adapter", :
|
25
|
-
gem "activerecord-jdbcmysql-adapter", :
|
26
|
-
gem "activerecord-jdbcpostgresql-adapter", :
|
27
|
-
gem "activerecord-jdbcmssql-adapter", :
|
22
|
+
gem 'activerecord-jdbc-adapter', github: 'jruby/activerecord-jdbc-adapter', tag: 'v51.0', platforms: :jruby
|
23
|
+
gem "jdbc-sqlite3", platforms: :jruby
|
24
|
+
gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
|
25
|
+
gem "activerecord-jdbcmysql-adapter", platforms: :jruby
|
26
|
+
gem "activerecord-jdbcpostgresql-adapter", platforms: :jruby
|
27
|
+
gem "activerecord-jdbcmssql-adapter", platforms: :jruby
|
28
28
|
end
|
29
29
|
|
30
|
-
gemspec :
|
30
|
+
gemspec path: "../"
|
data/gemfiles/rails5_2.gemfile
CHANGED
@@ -8,23 +8,23 @@ group :development, :test do
|
|
8
8
|
gem 'activemodel', '~> 5.2.0'
|
9
9
|
gem 'activerecord', '~> 5.2.0'
|
10
10
|
|
11
|
-
gem "sqlite3", '<= 1.3.13', :
|
12
|
-
gem "mysql2", '0.4.10', :
|
13
|
-
gem "pg",'< 1.0.0', :
|
11
|
+
gem "sqlite3", '<= 1.3.13', platforms: [:mri, :mswin, :mingw]
|
12
|
+
gem "mysql2", '0.4.10', platforms: [:mri, :mswin, :mingw]
|
13
|
+
gem "pg",'< 1.0.0', platforms: [:mri, :mingw]
|
14
14
|
|
15
|
-
gem "tiny_tds", :
|
16
|
-
#gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw]
|
15
|
+
gem "tiny_tds", platforms: [:mri, :mingw] if RUBY_PLATFORM =~ /windows/
|
16
|
+
# gem "activerecord-sqlserver-adapter", :platforms => [:mri, :mingw]
|
17
17
|
|
18
|
-
gem 'ruby-oci8', :
|
18
|
+
gem 'ruby-oci8', platforms: [:mri, :mswin, :mingw] if ENV.has_key? 'ORACLE_HOME'
|
19
19
|
gem 'activerecord-oracle_enhanced-adapter', '~> 5.2.0' if ENV.has_key? 'ORACLE_HOME'
|
20
20
|
|
21
21
|
# for JRuby
|
22
|
-
gem 'activerecord-jdbc-adapter', :
|
23
|
-
gem "jdbc-sqlite3", :
|
24
|
-
gem "activerecord-jdbcsqlite3-adapter", :
|
25
|
-
gem "activerecord-jdbcmysql-adapter", :
|
26
|
-
gem "activerecord-jdbcpostgresql-adapter", :
|
27
|
-
gem "activerecord-jdbcmssql-adapter", :
|
22
|
+
gem 'activerecord-jdbc-adapter', github: 'jruby/activerecord-jdbc-adapter', tag: 'v52.0', platforms: :jruby
|
23
|
+
gem "jdbc-sqlite3", platforms: :jruby
|
24
|
+
gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
|
25
|
+
gem "activerecord-jdbcmysql-adapter", platforms: :jruby
|
26
|
+
gem "activerecord-jdbcpostgresql-adapter", platforms: :jruby
|
27
|
+
gem "activerecord-jdbcmssql-adapter", platforms: :jruby
|
28
28
|
end
|
29
29
|
|
30
|
-
gemspec :
|
30
|
+
gemspec path: "../"
|
data/gemfiles/rails6.gemfile
CHANGED
@@ -8,23 +8,23 @@ group :development, :test do
|
|
8
8
|
gem 'activemodel', '~> 6.0.0'
|
9
9
|
gem 'activerecord', '~> 6.0.0'
|
10
10
|
|
11
|
-
gem "sqlite3", '~> 1.4', :
|
12
|
-
gem "mysql2", '0.5.2', :
|
13
|
-
gem "pg",'< 1.0.0', :
|
11
|
+
gem "sqlite3", '~> 1.4', platforms: [:mri, :mswin, :mingw]
|
12
|
+
gem "mysql2", '0.5.2', platforms: [:mri, :mswin, :mingw]
|
13
|
+
gem "pg",'< 1.0.0', platforms: [:mri, :mingw]
|
14
14
|
|
15
|
-
gem "tiny_tds", :
|
16
|
-
gem "activerecord-sqlserver-adapter", :
|
15
|
+
#gem "tiny_tds", platforms: [:mri, :mingw] if RUBY_PLATFORM =~ /windows/
|
16
|
+
#gem "activerecord-sqlserver-adapter", platforms: [:mri, :mingw]
|
17
17
|
|
18
|
-
gem 'ruby-oci8', :
|
18
|
+
gem 'ruby-oci8', platforms: [:mri, :mswin, :mingw] if ENV.has_key? 'ORACLE_HOME'
|
19
19
|
gem 'activerecord-oracle_enhanced-adapter', '~> 6.0.0' if ENV.has_key? 'ORACLE_HOME'
|
20
20
|
|
21
21
|
# for JRuby
|
22
|
-
gem 'activerecord-jdbc-adapter', :
|
23
|
-
gem "jdbc-sqlite3", :
|
24
|
-
gem "activerecord-jdbcsqlite3-adapter", :
|
25
|
-
gem "activerecord-jdbcmysql-adapter", :
|
26
|
-
gem "activerecord-jdbcpostgresql-adapter", :
|
27
|
-
gem "activerecord-jdbcmssql-adapter", :
|
22
|
+
gem 'activerecord-jdbc-adapter', platforms: :jruby
|
23
|
+
gem "jdbc-sqlite3", platforms: :jruby
|
24
|
+
gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
|
25
|
+
gem "activerecord-jdbcmysql-adapter", platforms: :jruby
|
26
|
+
gem "activerecord-jdbcpostgresql-adapter", platforms: :jruby
|
27
|
+
gem "activerecord-jdbcmssql-adapter", platforms: :jruby
|
28
28
|
end
|
29
29
|
|
30
|
-
gemspec :
|
30
|
+
gemspec path: "../"
|
@@ -0,0 +1,30 @@
|
|
1
|
+
source "https://rubygems.org"
|
2
|
+
|
3
|
+
gem 'rails', '~> 6.1.0'
|
4
|
+
|
5
|
+
|
6
|
+
group :development, :test do
|
7
|
+
gem 'activesupport', '~> 6.1.0'
|
8
|
+
gem 'activemodel', '~> 6.1.0'
|
9
|
+
gem 'activerecord', '~> 6.1.0'
|
10
|
+
|
11
|
+
gem "sqlite3", '~> 1.4', platforms: [:mri, :mswin, :mingw]
|
12
|
+
gem "mysql2", '0.5.2', platforms: [:mri, :mswin, :mingw]
|
13
|
+
gem "pg",'~> 1.1', platforms: [:mri, :mingw]
|
14
|
+
|
15
|
+
#gem "tiny_tds", platforms: [:mri, :mingw] if RUBY_PLATFORM =~ /windows/
|
16
|
+
#gem "activerecord-sqlserver-adapter", platforms: [:mri, :mingw]
|
17
|
+
|
18
|
+
gem 'ruby-oci8', platforms: [:mri, :mswin, :mingw] if ENV.has_key? 'ORACLE_HOME'
|
19
|
+
gem 'activerecord-oracle_enhanced-adapter', '~> 6.0.0' if ENV.has_key? 'ORACLE_HOME'
|
20
|
+
|
21
|
+
# for JRuby
|
22
|
+
gem 'activerecord-jdbc-adapter', platforms: :jruby
|
23
|
+
gem "jdbc-sqlite3", platforms: :jruby
|
24
|
+
gem "activerecord-jdbcsqlite3-adapter", platforms: :jruby
|
25
|
+
gem "activerecord-jdbcmysql-adapter", platforms: :jruby
|
26
|
+
gem "activerecord-jdbcpostgresql-adapter", platforms: :jruby
|
27
|
+
gem "activerecord-jdbcmssql-adapter", platforms: :jruby
|
28
|
+
end
|
29
|
+
|
30
|
+
gemspec path: "../"
|
@@ -0,0 +1,28 @@
|
|
1
|
+
$:.push File.expand_path("../lib", __FILE__)
|
2
|
+
require "arel_extensions/version"
|
3
|
+
|
4
|
+
Gem::Specification.new do |s|
|
5
|
+
s.name = "arel_extensions"
|
6
|
+
s.version = ArelExtensions::VERSION
|
7
|
+
s.platform = Gem::Platform::RUBY
|
8
|
+
s.authors = ["Yann Azoury", "Félix Bellanger", "Julien Delporte"]
|
9
|
+
s.email = ["yann.azoury@faveod.com", "felix.bellanger@faveod.com", "julien.delporte@faveod.com"]
|
10
|
+
s.homepage = "https://github.com/Faveod/arel-extensions"
|
11
|
+
s.description = "Adds new features to Arel"
|
12
|
+
s.summary = "Extending Arel"
|
13
|
+
s.license = 'MIT'
|
14
|
+
|
15
|
+
s.rdoc_options = ["--main", "README.md"]
|
16
|
+
s.extra_rdoc_files = ["MIT-LICENSE.txt", "README.md", 'functions.html']
|
17
|
+
|
18
|
+
# Manifest
|
19
|
+
s.files = `git ls-files`.split("\n")
|
20
|
+
s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
|
21
|
+
s.require_paths = ["lib"]
|
22
|
+
|
23
|
+
s.add_dependency('arel', '>= 6.0')
|
24
|
+
|
25
|
+
s.add_development_dependency('minitest', '~> 5.9')
|
26
|
+
s.add_development_dependency('rdoc', '~> 4.0')
|
27
|
+
s.add_development_dependency('rake', '~> 12.3.3')
|
28
|
+
end
|