schema_plus_core 2.2.1 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/prs.yml +134 -0
- data/.gitignore +1 -0
- data/.simplecov +20 -0
- data/Gemfile +2 -0
- data/README.md +10 -9
- data/Rakefile +2 -0
- data/gemfiles/Gemfile.base +1 -1
- data/gemfiles/activerecord-5.2/Gemfile.base +2 -1
- data/gemfiles/activerecord-5.2/Gemfile.mysql2 +2 -2
- data/gemfiles/activerecord-5.2/Gemfile.postgresql +2 -2
- data/gemfiles/activerecord-5.2/Gemfile.sqlite3 +3 -3
- data/gemfiles/activerecord-6.0/Gemfile.base +4 -0
- data/gemfiles/activerecord-6.0/Gemfile.mysql2 +10 -0
- data/gemfiles/activerecord-6.0/Gemfile.postgresql +10 -0
- data/gemfiles/{activerecord-5.0 → activerecord-6.0}/Gemfile.sqlite3 +3 -3
- data/lib/schema_plus/core/active_record/base.rb +6 -4
- data/lib/schema_plus/core/active_record/connection_adapters/abstract_adapter.rb +15 -13
- data/lib/schema_plus/core/active_record/connection_adapters/mysql2_adapter.rb +8 -6
- data/lib/schema_plus/core/active_record/connection_adapters/postgresql/schema_dumper.rb +3 -2
- data/lib/schema_plus/core/active_record/connection_adapters/postgresql_adapter.rb +9 -25
- data/lib/schema_plus/core/active_record/connection_adapters/sqlite3_adapter.rb +6 -4
- data/lib/schema_plus/core/active_record/connection_adapters/table_definition.rb +8 -8
- data/lib/schema_plus/core/active_record/migration/command_recorder.rb +4 -2
- data/lib/schema_plus/core/active_record/schema.rb +2 -0
- data/lib/schema_plus/core/active_record/schema_dumper.rb +56 -27
- data/lib/schema_plus/core/middleware.rb +2 -0
- data/lib/schema_plus/core/schema_dump.rb +6 -3
- data/lib/schema_plus/core/sql_struct.rb +4 -2
- data/lib/schema_plus/core/version.rb +3 -1
- data/lib/schema_plus/core.rb +3 -4
- data/schema_dev.yml +5 -5
- data/schema_plus_core.gemspec +9 -10
- data/spec/column_spec.rb +3 -2
- data/spec/dumper_spec.rb +25 -0
- data/spec/index_spec.rb +2 -0
- data/spec/middleware_spec.rb +5 -2
- data/spec/spec_helper.rb +9 -2
- data/spec/sql_struct_spec.rb +2 -0
- data/spec/support/enableable.rb +2 -4
- data/spec/support/test_reporter.rb +3 -1
- metadata +33 -87
- data/.travis.yml +0 -25
- data/gemfiles/activerecord-5.0/Gemfile.base +0 -3
- data/gemfiles/activerecord-5.0/Gemfile.mysql2 +0 -10
- data/gemfiles/activerecord-5.0/Gemfile.postgresql +0 -10
- data/gemfiles/activerecord-5.1/Gemfile.base +0 -3
- data/gemfiles/activerecord-5.1/Gemfile.mysql2 +0 -10
- data/gemfiles/activerecord-5.1/Gemfile.postgresql +0 -10
- data/gemfiles/activerecord-5.1/Gemfile.sqlite3 +0 -10
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
require 'ostruct'
|
|
2
4
|
require 'tsort'
|
|
3
5
|
|
|
@@ -44,6 +46,54 @@ module SchemaPlus
|
|
|
44
46
|
end
|
|
45
47
|
end
|
|
46
48
|
|
|
49
|
+
TABLE_COLUMN_MATCHES = [
|
|
50
|
+
[ # first match expression index case
|
|
51
|
+
%r{
|
|
52
|
+
^
|
|
53
|
+
t\.index \s*
|
|
54
|
+
"(?<index_cols>(?:[^"\\]|\\.)*?)" \s*
|
|
55
|
+
, \s*
|
|
56
|
+
name\: \s* [:'"](?<name>[^"\s]+)[,"]? \s*
|
|
57
|
+
,? \s*
|
|
58
|
+
(?<options>.*)
|
|
59
|
+
$
|
|
60
|
+
}x,
|
|
61
|
+
->(m) {
|
|
62
|
+
index_cols = m[:index_cols].gsub('\\"', '"')
|
|
63
|
+
SchemaDump::Table::Index.new name: m[:name], columns: index_cols, options: eval("{" + m[:options] + "}")
|
|
64
|
+
}
|
|
65
|
+
],
|
|
66
|
+
[ # general matching of columns
|
|
67
|
+
%r{
|
|
68
|
+
^
|
|
69
|
+
t\.(?<type>\S+) \s*
|
|
70
|
+
[:'"](?<name>[^"\s]+)[,"]? \s*
|
|
71
|
+
,? \s*
|
|
72
|
+
(?<options>.*)
|
|
73
|
+
$
|
|
74
|
+
}x,
|
|
75
|
+
->(m) {
|
|
76
|
+
SchemaDump::Table::Column.new name: m[:name], type: m[:type], options: eval("{" + m[:options] + "}"), comments: []
|
|
77
|
+
}
|
|
78
|
+
],
|
|
79
|
+
[ # index definitions with multiple columns
|
|
80
|
+
%r{
|
|
81
|
+
^
|
|
82
|
+
t\.index \s*
|
|
83
|
+
\[(?<index_cols>.*?)\] \s*
|
|
84
|
+
, \s*
|
|
85
|
+
name\: \s* [:'"](?<name>[^"\s]+)[,"]? \s*
|
|
86
|
+
,? \s*
|
|
87
|
+
(?<options>.*)
|
|
88
|
+
$
|
|
89
|
+
}x,
|
|
90
|
+
->(m) {
|
|
91
|
+
index_cols = m[:index_cols].tr(%q{'":}, '').strip.split(/\s*,\s*/)
|
|
92
|
+
SchemaDump::Table::Index.new name: m[:name], columns: index_cols, options: eval("{#{m[:options]}}")
|
|
93
|
+
}
|
|
94
|
+
]
|
|
95
|
+
].freeze
|
|
96
|
+
|
|
47
97
|
def table(table, _)
|
|
48
98
|
SchemaMonkey::Middleware::Dumper::Table.start(dumper: self, connection: @connection, dump: @dump, table: @dump.tables[table] = SchemaDump::Table.new(name: table)) do |env|
|
|
49
99
|
stream = StringIO.new
|
|
@@ -68,34 +118,13 @@ module SchemaPlus
|
|
|
68
118
|
env.table.trailer = m[:trailer].split("\n").map(&:strip).reject{|s| s.blank?}
|
|
69
119
|
table_objects = m[:columns].strip.split("\n").map { |col|
|
|
70
120
|
cs = col.strip
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
(?<options>.*)
|
|
77
|
-
$
|
|
78
|
-
}x
|
|
79
|
-
if !m.nil?
|
|
80
|
-
SchemaDump::Table::Column.new name: m[:name], type: m[:type], options: eval("{" + m[:options] + "}"), comments: []
|
|
81
|
-
else
|
|
82
|
-
m = cs.match %r{
|
|
83
|
-
^
|
|
84
|
-
t\.index \s*
|
|
85
|
-
\[(?<index_cols>.*?)\] \s*
|
|
86
|
-
, \s*
|
|
87
|
-
name\: \s* [:'"](?<name>[^"\s]+)[,"]? \s*
|
|
88
|
-
,? \s*
|
|
89
|
-
(?<options>.*)
|
|
90
|
-
$
|
|
91
|
-
}x
|
|
92
|
-
if m.nil?
|
|
93
|
-
nil
|
|
94
|
-
else
|
|
95
|
-
index_cols = m[:index_cols].tr(%q{'":}, '').strip.split(/\s*,\s*/)
|
|
96
|
-
SchemaDump::Table::Index.new name: m[:name], columns: index_cols, options: eval("{#{m[:options]}}")
|
|
97
|
-
end
|
|
121
|
+
result = nil
|
|
122
|
+
# find the first regex that matches and grab the column definition
|
|
123
|
+
TABLE_COLUMN_MATCHES.find do |(r, l)|
|
|
124
|
+
m = cs.match r
|
|
125
|
+
result = m.nil? ? nil : l.call(m)
|
|
98
126
|
end
|
|
127
|
+
result
|
|
99
128
|
}.reject { |o| o.nil? }
|
|
100
129
|
env.table.columns = table_objects.select { |o| o.is_a? SchemaDump::Table::Column }
|
|
101
130
|
env.table.indexes = table_objects.select { |o| o.is_a? SchemaDump::Table::Index }
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
module SchemaPlus
|
|
2
4
|
module Core
|
|
3
5
|
class SchemaDump
|
|
@@ -43,7 +45,8 @@ module SchemaPlus
|
|
|
43
45
|
@dependencies[tablename].sort.uniq.reject{|t| @dumper.ignored? t}.each(&block)
|
|
44
46
|
end
|
|
45
47
|
|
|
46
|
-
class Table <
|
|
48
|
+
class Table < Struct.new(:name, :pname, :options, :columns, :indexes, :statements, :trailer, :alt,
|
|
49
|
+
keyword_init: true)
|
|
47
50
|
def initialize(*args)
|
|
48
51
|
super
|
|
49
52
|
self.columns ||= []
|
|
@@ -85,7 +88,7 @@ module SchemaPlus
|
|
|
85
88
|
stream.puts ""
|
|
86
89
|
end
|
|
87
90
|
|
|
88
|
-
class Column <
|
|
91
|
+
class Column < Struct.new(:name, :type, :options, :comments, keyword_init: true)
|
|
89
92
|
|
|
90
93
|
def assemble(stream, typelen, namelen)
|
|
91
94
|
stream.write "t.%-#{typelen}s " % type
|
|
@@ -102,7 +105,7 @@ module SchemaPlus
|
|
|
102
105
|
end
|
|
103
106
|
end
|
|
104
107
|
|
|
105
|
-
class Index <
|
|
108
|
+
class Index < Struct.new(:name, :columns, :options, keyword_init: true)
|
|
106
109
|
|
|
107
110
|
def assemble(stream)
|
|
108
111
|
stream.write columns.inspect + ", " + {name: name}.merge(options).to_s.sub(/^{(.*)}$/, '\1')
|
|
@@ -1,9 +1,11 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
module SchemaPlus
|
|
2
4
|
module Core
|
|
3
5
|
module SqlStruct
|
|
4
|
-
IndexComponents =
|
|
6
|
+
IndexComponents = Struct.new(:name, :type, :columns, :options, :algorithm, :using, keyword_init: true)
|
|
5
7
|
|
|
6
|
-
class Table <
|
|
8
|
+
class Table < Struct.new(:command, :name, :body, :options, :quotechar, :inheritance, keyword_init: true)
|
|
7
9
|
|
|
8
10
|
INHERITANCE_REGEX = %r{ \s* (?<inheritance>INHERITS \s* \( [^)]* \)) }mxi
|
|
9
11
|
|
data/lib/schema_plus/core.rb
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
require "schema_monkey"
|
|
2
|
-
require 'its-it'
|
|
3
4
|
require "pathname"
|
|
4
5
|
|
|
5
6
|
module SchemaPlus
|
|
@@ -26,8 +27,6 @@ require_relative "core/schema_dump"
|
|
|
26
27
|
require_relative "core/sql_struct"
|
|
27
28
|
require_relative "core/version"
|
|
28
29
|
|
|
29
|
-
|
|
30
|
-
require_relative "core/active_record/connection_adapters/postgresql/schema_dumper"
|
|
31
|
-
end
|
|
30
|
+
require_relative "core/active_record/connection_adapters/postgresql/schema_dumper"
|
|
32
31
|
|
|
33
32
|
SchemaMonkey.register(SchemaPlus::Core)
|
data/schema_dev.yml
CHANGED
data/schema_plus_core.gemspec
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
#
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
2
3
|
lib = File.expand_path('../lib', __FILE__)
|
|
3
4
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
4
5
|
require 'schema_plus/core/version'
|
|
@@ -18,16 +19,14 @@ Gem::Specification.new do |gem|
|
|
|
18
19
|
gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
|
|
19
20
|
gem.require_paths = ["lib"]
|
|
20
21
|
|
|
21
|
-
gem.
|
|
22
|
-
|
|
23
|
-
gem.add_dependency "
|
|
22
|
+
gem.required_ruby_version = ">= 2.5.0"
|
|
23
|
+
|
|
24
|
+
gem.add_dependency "activerecord", ">= 5.2", "< 6.1"
|
|
25
|
+
gem.add_dependency "schema_monkey", "~> 3.0.1"
|
|
24
26
|
|
|
25
|
-
gem.add_development_dependency "bundler"
|
|
26
|
-
gem.add_development_dependency "rake", "~>
|
|
27
|
+
gem.add_development_dependency "bundler"
|
|
28
|
+
gem.add_development_dependency "rake", "~> 13.0.0"
|
|
27
29
|
gem.add_development_dependency "rspec", "~> 3.0"
|
|
28
30
|
gem.add_development_dependency "rspec-given"
|
|
29
|
-
gem.add_development_dependency "schema_dev", "~>
|
|
30
|
-
gem.add_development_dependency "simplecov"
|
|
31
|
-
gem.add_development_dependency "simplecov-gem-profile"
|
|
32
|
-
gem.add_development_dependency "its-it"
|
|
31
|
+
gem.add_development_dependency "schema_dev", "~> 4.1"
|
|
33
32
|
end
|
data/spec/column_spec.rb
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
require 'spec_helper'
|
|
2
4
|
|
|
3
5
|
module TestImplementsReference
|
|
@@ -27,8 +29,7 @@ describe SchemaMonkey::Middleware::Migration::Column do
|
|
|
27
29
|
let (:spy) { described_class.const_get(:SPY) }
|
|
28
30
|
|
|
29
31
|
let (:pk_type) do
|
|
30
|
-
if ActiveRecord
|
|
31
|
-
ActiveRecord::Base.connection.adapter_name =~ /mysql|postgresql/i
|
|
32
|
+
if ActiveRecord::Base.connection.adapter_name =~ /mysql|postgresql/i
|
|
32
33
|
:bigint
|
|
33
34
|
else
|
|
34
35
|
:integer
|
data/spec/dumper_spec.rb
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
require 'spec_helper'
|
|
2
4
|
|
|
3
5
|
module TestDumper
|
|
@@ -82,6 +84,29 @@ describe SchemaMonkey::Middleware::Dumper do
|
|
|
82
84
|
|
|
83
85
|
context TestDumper::Middleware::Dumper::Tables do
|
|
84
86
|
Then { expect(dump).to match(/create_table "other".*create_table "#{middleware}".*create_table "things"/m) }
|
|
87
|
+
|
|
88
|
+
context 'int PK handling in rails 5.2+', postgresql: :only do
|
|
89
|
+
before(:each) do
|
|
90
|
+
migration.create_table "inttable", id: :serial do |t|
|
|
91
|
+
end
|
|
92
|
+
end
|
|
93
|
+
|
|
94
|
+
Then { expect(dump).to_not match(/create_table "inttable", id: :serial.*default:/m) }
|
|
95
|
+
end
|
|
96
|
+
|
|
97
|
+
context 'expression index handling', postgresql: :only do
|
|
98
|
+
before(:each) do
|
|
99
|
+
migration.create_table "expressions" do |t|
|
|
100
|
+
t.string :field
|
|
101
|
+
t.string :column
|
|
102
|
+
t.index 'lower(field), id', name: 'index_expression_field'
|
|
103
|
+
t.index 'lower("column"), id', name: 'index_expression_column'
|
|
104
|
+
end
|
|
105
|
+
end
|
|
106
|
+
|
|
107
|
+
Then { expect(dump).to match(/index "lower.+field.+, id", :name=>"index_expression_field"/) }
|
|
108
|
+
Then { expect(dump).to match(/index "lower.+"column\\".+, id", :name=>"index_expression_column"/) }
|
|
109
|
+
end
|
|
85
110
|
end
|
|
86
111
|
|
|
87
112
|
context TestDumper::Middleware::Dumper::Table do
|
data/spec/index_spec.rb
CHANGED
data/spec/middleware_spec.rb
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
require 'spec_helper'
|
|
2
4
|
|
|
3
5
|
describe SchemaMonkey::Middleware do
|
|
@@ -17,7 +19,7 @@ describe SchemaMonkey::Middleware do
|
|
|
17
19
|
|
|
18
20
|
context TestReporter::Middleware::Query::Exec do
|
|
19
21
|
Then { expect_middleware(enable: {sql: /SELECT column1/}) { connection.select_values("SELECT column1 FROM things") } }
|
|
20
|
-
Then { expect_middleware(enable: {sql: /^UPDATE/}) { thing.
|
|
22
|
+
Then { expect_middleware(enable: {sql: /^UPDATE/}) { thing.update!(column1: 3) } }
|
|
21
23
|
Then { expect_middleware(enable: {sql: /^DELETE/}) { thing.delete } }
|
|
22
24
|
end
|
|
23
25
|
end
|
|
@@ -30,7 +32,7 @@ describe SchemaMonkey::Middleware do
|
|
|
30
32
|
end
|
|
31
33
|
|
|
32
34
|
context TestReporter::Middleware::Schema::DataSources do
|
|
33
|
-
Then { expect_middleware { connection.data_sources
|
|
35
|
+
Then { expect_middleware { connection.data_sources } }
|
|
34
36
|
end
|
|
35
37
|
|
|
36
38
|
context TestReporter::Middleware::Schema::Indexes do
|
|
@@ -119,6 +121,7 @@ describe SchemaMonkey::Middleware do
|
|
|
119
121
|
end
|
|
120
122
|
|
|
121
123
|
Then do
|
|
124
|
+
|
|
122
125
|
class TestThingamajig < ActiveRecord::Base
|
|
123
126
|
has_and_belongs_to_many :other_things, join_table: 'another_table'
|
|
124
127
|
end
|
data/spec/spec_helper.rb
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
require 'simplecov'
|
|
2
|
-
|
|
3
|
-
SimpleCov.start "gem"
|
|
4
|
+
SimpleCov.start
|
|
4
5
|
|
|
5
6
|
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
|
6
7
|
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
|
@@ -16,6 +17,12 @@ Dir[File.dirname(__FILE__) + "/support/**/*.rb"].each {|f| require f}
|
|
|
16
17
|
SchemaDev::Rspec.setup
|
|
17
18
|
|
|
18
19
|
RSpec.configure do |config|
|
|
20
|
+
|
|
21
|
+
config.filter_run_excluding rails: -> (v) {
|
|
22
|
+
rails_version = Gem::Version.new(ActiveRecord::VERSION::STRING)
|
|
23
|
+
test = Gem::Requirement.new(v)
|
|
24
|
+
!test.satisfied_by?(rails_version)
|
|
25
|
+
}
|
|
19
26
|
config.warnings = true
|
|
20
27
|
config.around(:each) do |example|
|
|
21
28
|
ActiveRecord::Migration.suppress_messages do
|
data/spec/sql_struct_spec.rb
CHANGED
data/spec/support/enableable.rb
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
module Enableable
|
|
4
4
|
|
|
5
5
|
def enabled_middleware(root, env)
|
|
6
|
-
middleware = self.singleton_class.ancestors.find
|
|
6
|
+
middleware = self.singleton_class.ancestors.find { |it| it.to_s.start_with?("#{root}::Middleware") }
|
|
7
7
|
return nil unless middleware.enabled?(env)
|
|
8
8
|
middleware.disable if middleware.once?(env)
|
|
9
9
|
middleware
|
|
@@ -32,5 +32,3 @@ module Enableable
|
|
|
32
32
|
end
|
|
33
33
|
end
|
|
34
34
|
end
|
|
35
|
-
|
|
36
|
-
|
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
1
3
|
module TestReporter
|
|
2
4
|
|
|
3
5
|
class Called < Exception
|
|
@@ -15,7 +17,7 @@ module TestReporter
|
|
|
15
17
|
|
|
16
18
|
def after(env)
|
|
17
19
|
return unless middleware = enabled_middleware(TestReporter, env)
|
|
18
|
-
raise Called
|
|
20
|
+
raise Called.new middleware: middleware, env: env
|
|
19
21
|
end
|
|
20
22
|
end
|
|
21
23
|
|
metadata
CHANGED
|
@@ -1,85 +1,77 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: schema_plus_core
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version:
|
|
4
|
+
version: 3.0.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- ronen barzel
|
|
8
|
-
autorequire:
|
|
8
|
+
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2022-04-22 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: activerecord
|
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
|
16
16
|
requirements:
|
|
17
|
-
- - "
|
|
18
|
-
- !ruby/object:Gem::Version
|
|
19
|
-
version: '5.0'
|
|
20
|
-
type: :runtime
|
|
21
|
-
prerelease: false
|
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
23
|
-
requirements:
|
|
24
|
-
- - "~>"
|
|
17
|
+
- - ">="
|
|
25
18
|
- !ruby/object:Gem::Version
|
|
26
|
-
version: '5.
|
|
27
|
-
-
|
|
28
|
-
name: schema_monkey
|
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
|
30
|
-
requirements:
|
|
31
|
-
- - "~>"
|
|
19
|
+
version: '5.2'
|
|
20
|
+
- - "<"
|
|
32
21
|
- !ruby/object:Gem::Version
|
|
33
|
-
version: '
|
|
22
|
+
version: '6.1'
|
|
34
23
|
type: :runtime
|
|
35
24
|
prerelease: false
|
|
36
25
|
version_requirements: !ruby/object:Gem::Requirement
|
|
37
26
|
requirements:
|
|
38
|
-
- - "
|
|
27
|
+
- - ">="
|
|
28
|
+
- !ruby/object:Gem::Version
|
|
29
|
+
version: '5.2'
|
|
30
|
+
- - "<"
|
|
39
31
|
- !ruby/object:Gem::Version
|
|
40
|
-
version: '
|
|
32
|
+
version: '6.1'
|
|
41
33
|
- !ruby/object:Gem::Dependency
|
|
42
|
-
name:
|
|
34
|
+
name: schema_monkey
|
|
43
35
|
requirement: !ruby/object:Gem::Requirement
|
|
44
36
|
requirements:
|
|
45
37
|
- - "~>"
|
|
46
38
|
- !ruby/object:Gem::Version
|
|
47
|
-
version:
|
|
39
|
+
version: 3.0.1
|
|
48
40
|
type: :runtime
|
|
49
41
|
prerelease: false
|
|
50
42
|
version_requirements: !ruby/object:Gem::Requirement
|
|
51
43
|
requirements:
|
|
52
44
|
- - "~>"
|
|
53
45
|
- !ruby/object:Gem::Version
|
|
54
|
-
version:
|
|
46
|
+
version: 3.0.1
|
|
55
47
|
- !ruby/object:Gem::Dependency
|
|
56
48
|
name: bundler
|
|
57
49
|
requirement: !ruby/object:Gem::Requirement
|
|
58
50
|
requirements:
|
|
59
|
-
- - "
|
|
51
|
+
- - ">="
|
|
60
52
|
- !ruby/object:Gem::Version
|
|
61
|
-
version: '
|
|
53
|
+
version: '0'
|
|
62
54
|
type: :development
|
|
63
55
|
prerelease: false
|
|
64
56
|
version_requirements: !ruby/object:Gem::Requirement
|
|
65
57
|
requirements:
|
|
66
|
-
- - "
|
|
58
|
+
- - ">="
|
|
67
59
|
- !ruby/object:Gem::Version
|
|
68
|
-
version: '
|
|
60
|
+
version: '0'
|
|
69
61
|
- !ruby/object:Gem::Dependency
|
|
70
62
|
name: rake
|
|
71
63
|
requirement: !ruby/object:Gem::Requirement
|
|
72
64
|
requirements:
|
|
73
65
|
- - "~>"
|
|
74
66
|
- !ruby/object:Gem::Version
|
|
75
|
-
version:
|
|
67
|
+
version: 13.0.0
|
|
76
68
|
type: :development
|
|
77
69
|
prerelease: false
|
|
78
70
|
version_requirements: !ruby/object:Gem::Requirement
|
|
79
71
|
requirements:
|
|
80
72
|
- - "~>"
|
|
81
73
|
- !ruby/object:Gem::Version
|
|
82
|
-
version:
|
|
74
|
+
version: 13.0.0
|
|
83
75
|
- !ruby/object:Gem::Dependency
|
|
84
76
|
name: rspec
|
|
85
77
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -114,56 +106,14 @@ dependencies:
|
|
|
114
106
|
requirements:
|
|
115
107
|
- - "~>"
|
|
116
108
|
- !ruby/object:Gem::Version
|
|
117
|
-
version: '
|
|
109
|
+
version: '4.1'
|
|
118
110
|
type: :development
|
|
119
111
|
prerelease: false
|
|
120
112
|
version_requirements: !ruby/object:Gem::Requirement
|
|
121
113
|
requirements:
|
|
122
114
|
- - "~>"
|
|
123
115
|
- !ruby/object:Gem::Version
|
|
124
|
-
version: '
|
|
125
|
-
- !ruby/object:Gem::Dependency
|
|
126
|
-
name: simplecov
|
|
127
|
-
requirement: !ruby/object:Gem::Requirement
|
|
128
|
-
requirements:
|
|
129
|
-
- - ">="
|
|
130
|
-
- !ruby/object:Gem::Version
|
|
131
|
-
version: '0'
|
|
132
|
-
type: :development
|
|
133
|
-
prerelease: false
|
|
134
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
135
|
-
requirements:
|
|
136
|
-
- - ">="
|
|
137
|
-
- !ruby/object:Gem::Version
|
|
138
|
-
version: '0'
|
|
139
|
-
- !ruby/object:Gem::Dependency
|
|
140
|
-
name: simplecov-gem-profile
|
|
141
|
-
requirement: !ruby/object:Gem::Requirement
|
|
142
|
-
requirements:
|
|
143
|
-
- - ">="
|
|
144
|
-
- !ruby/object:Gem::Version
|
|
145
|
-
version: '0'
|
|
146
|
-
type: :development
|
|
147
|
-
prerelease: false
|
|
148
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
149
|
-
requirements:
|
|
150
|
-
- - ">="
|
|
151
|
-
- !ruby/object:Gem::Version
|
|
152
|
-
version: '0'
|
|
153
|
-
- !ruby/object:Gem::Dependency
|
|
154
|
-
name: its-it
|
|
155
|
-
requirement: !ruby/object:Gem::Requirement
|
|
156
|
-
requirements:
|
|
157
|
-
- - ">="
|
|
158
|
-
- !ruby/object:Gem::Version
|
|
159
|
-
version: '0'
|
|
160
|
-
type: :development
|
|
161
|
-
prerelease: false
|
|
162
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
163
|
-
requirements:
|
|
164
|
-
- - ">="
|
|
165
|
-
- !ruby/object:Gem::Version
|
|
166
|
-
version: '0'
|
|
116
|
+
version: '4.1'
|
|
167
117
|
description: Provides an internal extension API to ActiveRecord, in the form of middleware-style
|
|
168
118
|
callback stacks
|
|
169
119
|
email:
|
|
@@ -172,25 +122,22 @@ executables: []
|
|
|
172
122
|
extensions: []
|
|
173
123
|
extra_rdoc_files: []
|
|
174
124
|
files:
|
|
125
|
+
- ".github/workflows/prs.yml"
|
|
175
126
|
- ".gitignore"
|
|
176
|
-
- ".
|
|
127
|
+
- ".simplecov"
|
|
177
128
|
- Gemfile
|
|
178
129
|
- LICENSE.txt
|
|
179
130
|
- README.md
|
|
180
131
|
- Rakefile
|
|
181
132
|
- gemfiles/Gemfile.base
|
|
182
|
-
- gemfiles/activerecord-5.0/Gemfile.base
|
|
183
|
-
- gemfiles/activerecord-5.0/Gemfile.mysql2
|
|
184
|
-
- gemfiles/activerecord-5.0/Gemfile.postgresql
|
|
185
|
-
- gemfiles/activerecord-5.0/Gemfile.sqlite3
|
|
186
|
-
- gemfiles/activerecord-5.1/Gemfile.base
|
|
187
|
-
- gemfiles/activerecord-5.1/Gemfile.mysql2
|
|
188
|
-
- gemfiles/activerecord-5.1/Gemfile.postgresql
|
|
189
|
-
- gemfiles/activerecord-5.1/Gemfile.sqlite3
|
|
190
133
|
- gemfiles/activerecord-5.2/Gemfile.base
|
|
191
134
|
- gemfiles/activerecord-5.2/Gemfile.mysql2
|
|
192
135
|
- gemfiles/activerecord-5.2/Gemfile.postgresql
|
|
193
136
|
- gemfiles/activerecord-5.2/Gemfile.sqlite3
|
|
137
|
+
- gemfiles/activerecord-6.0/Gemfile.base
|
|
138
|
+
- gemfiles/activerecord-6.0/Gemfile.mysql2
|
|
139
|
+
- gemfiles/activerecord-6.0/Gemfile.postgresql
|
|
140
|
+
- gemfiles/activerecord-6.0/Gemfile.sqlite3
|
|
194
141
|
- lib/schema_plus/core.rb
|
|
195
142
|
- lib/schema_plus/core/active_record/base.rb
|
|
196
143
|
- lib/schema_plus/core/active_record/connection_adapters/abstract_adapter.rb
|
|
@@ -220,7 +167,7 @@ homepage: https://github.com/SchemaPlus/schema_plus_core
|
|
|
220
167
|
licenses:
|
|
221
168
|
- MIT
|
|
222
169
|
metadata: {}
|
|
223
|
-
post_install_message:
|
|
170
|
+
post_install_message:
|
|
224
171
|
rdoc_options: []
|
|
225
172
|
require_paths:
|
|
226
173
|
- lib
|
|
@@ -228,16 +175,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
228
175
|
requirements:
|
|
229
176
|
- - ">="
|
|
230
177
|
- !ruby/object:Gem::Version
|
|
231
|
-
version:
|
|
178
|
+
version: 2.5.0
|
|
232
179
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
233
180
|
requirements:
|
|
234
181
|
- - ">="
|
|
235
182
|
- !ruby/object:Gem::Version
|
|
236
183
|
version: '0'
|
|
237
184
|
requirements: []
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
signing_key:
|
|
185
|
+
rubygems_version: 3.0.8
|
|
186
|
+
signing_key:
|
|
241
187
|
specification_version: 4
|
|
242
188
|
summary: Provides an internal extension API to ActiveRecord
|
|
243
189
|
test_files:
|
data/.travis.yml
DELETED
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
# This file was auto-generated by the schema_dev tool, based on the data in
|
|
2
|
-
# ./schema_dev.yml
|
|
3
|
-
# Please do not edit this file; any changes will be overwritten next time
|
|
4
|
-
# schema_dev gets run.
|
|
5
|
-
---
|
|
6
|
-
sudo: false
|
|
7
|
-
rvm:
|
|
8
|
-
- 2.4.4
|
|
9
|
-
- 2.5.1
|
|
10
|
-
gemfile:
|
|
11
|
-
- gemfiles/activerecord-5.0/Gemfile.mysql2
|
|
12
|
-
- gemfiles/activerecord-5.0/Gemfile.postgresql
|
|
13
|
-
- gemfiles/activerecord-5.0/Gemfile.sqlite3
|
|
14
|
-
- gemfiles/activerecord-5.1/Gemfile.mysql2
|
|
15
|
-
- gemfiles/activerecord-5.1/Gemfile.postgresql
|
|
16
|
-
- gemfiles/activerecord-5.1/Gemfile.sqlite3
|
|
17
|
-
- gemfiles/activerecord-5.2/Gemfile.mysql2
|
|
18
|
-
- gemfiles/activerecord-5.2/Gemfile.postgresql
|
|
19
|
-
- gemfiles/activerecord-5.2/Gemfile.sqlite3
|
|
20
|
-
env: POSTGRESQL_DB_USER=postgres MYSQL_DB_USER=travis
|
|
21
|
-
addons:
|
|
22
|
-
postgresql: '9.4'
|
|
23
|
-
before_script: bundle exec rake create_databases
|
|
24
|
-
after_script: bundle exec rake drop_databases
|
|
25
|
-
script: bundle exec rake travis
|