pg_trunk 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +4 -15
- data/CHANGELOG.md +21 -0
- data/README.md +3 -1
- data/lib/pg_trunk/core/operation/attributes.rb +1 -1
- data/lib/pg_trunk/core/railtie/custom_types.rb +5 -6
- data/lib/pg_trunk/operations/check_constraints/add_check_constraint.rb +42 -33
- data/lib/pg_trunk/operations/check_constraints/drop_check_constraint.rb +51 -40
- data/lib/pg_trunk/operations/check_constraints/rename_check_constraint.rb +39 -30
- data/lib/pg_trunk/operations/check_constraints/validate_check_constraint.rb +28 -21
- data/lib/pg_trunk/operations/composite_types/change_composite_type.rb +59 -50
- data/lib/pg_trunk/operations/composite_types/create_composite_type.rb +23 -19
- data/lib/pg_trunk/operations/composite_types/drop_composite_type.rb +48 -43
- data/lib/pg_trunk/operations/composite_types/rename_composite_type.rb +15 -12
- data/lib/pg_trunk/operations/domains/change_domain.rb +53 -47
- data/lib/pg_trunk/operations/domains/create_domain.rb +28 -25
- data/lib/pg_trunk/operations/domains/drop_domain.rb +50 -41
- data/lib/pg_trunk/operations/domains/rename_domain.rb +17 -12
- data/lib/pg_trunk/operations/enums/change_enum.rb +37 -32
- data/lib/pg_trunk/operations/enums/create_enum.rb +23 -20
- data/lib/pg_trunk/operations/enums/drop_enum.rb +50 -39
- data/lib/pg_trunk/operations/enums/rename_enum.rb +17 -12
- data/lib/pg_trunk/operations/foreign_keys/add_foreign_key.rb +58 -49
- data/lib/pg_trunk/operations/foreign_keys/drop_foreign_key.rb +57 -48
- data/lib/pg_trunk/operations/foreign_keys/rename_foreign_key.rb +38 -29
- data/lib/pg_trunk/operations/functions/change_function.rb +53 -47
- data/lib/pg_trunk/operations/functions/create_function.rb +75 -64
- data/lib/pg_trunk/operations/functions/drop_function.rb +78 -65
- data/lib/pg_trunk/operations/functions/rename_function.rb +29 -22
- data/lib/pg_trunk/operations/materialized_views/change_materialized_view.rb +65 -55
- data/lib/pg_trunk/operations/materialized_views/create_materialized_view.rb +82 -71
- data/lib/pg_trunk/operations/materialized_views/drop_materialized_view.rb +59 -46
- data/lib/pg_trunk/operations/materialized_views/refresh_materialized_view.rb +29 -24
- data/lib/pg_trunk/operations/materialized_views/rename_materialized_view.rb +29 -22
- data/lib/pg_trunk/operations/procedures/change_procedure.rb +53 -46
- data/lib/pg_trunk/operations/procedures/create_procedure.rb +63 -52
- data/lib/pg_trunk/operations/procedures/drop_procedure.rb +56 -45
- data/lib/pg_trunk/operations/procedures/rename_procedure.rb +29 -22
- data/lib/pg_trunk/operations/rules/base.rb +77 -0
- data/lib/pg_trunk/operations/rules/create_rule.rb +155 -0
- data/lib/pg_trunk/operations/rules/drop_rule.rb +94 -0
- data/lib/pg_trunk/operations/rules/rename_rule.rb +62 -0
- data/lib/pg_trunk/operations/rules.rb +13 -0
- data/lib/pg_trunk/operations/sequences/base.rb +79 -0
- data/lib/pg_trunk/operations/sequences/change_sequence.rb +142 -0
- data/lib/pg_trunk/operations/sequences/create_sequence.rb +180 -0
- data/lib/pg_trunk/operations/sequences/drop_sequence.rb +82 -0
- data/lib/pg_trunk/operations/sequences/rename_sequence.rb +64 -0
- data/lib/pg_trunk/operations/sequences.rb +14 -0
- data/lib/pg_trunk/operations/statistics/create_statistics.rb +67 -56
- data/lib/pg_trunk/operations/statistics/drop_statistics.rb +64 -53
- data/lib/pg_trunk/operations/statistics/rename_statistics.rb +18 -13
- data/lib/pg_trunk/operations/triggers/change_trigger.rb +23 -18
- data/lib/pg_trunk/operations/triggers/create_trigger.rb +63 -54
- data/lib/pg_trunk/operations/triggers/drop_trigger.rb +55 -46
- data/lib/pg_trunk/operations/triggers/rename_trigger.rb +51 -48
- data/lib/pg_trunk/operations/views/change_view.rb +47 -38
- data/lib/pg_trunk/operations/views/create_view.rb +56 -45
- data/lib/pg_trunk/operations/views/drop_view.rb +59 -46
- data/lib/pg_trunk/operations/views/rename_view.rb +27 -20
- data/lib/pg_trunk/operations.rb +2 -0
- data/lib/pg_trunk/version.rb +1 -1
- data/pg_trunk.gemspec +0 -1
- data/spec/operations/rules/create_rule_spec.rb +119 -0
- data/spec/operations/rules/drop_rule_spec.rb +117 -0
- data/spec/operations/rules/rename_rule_spec.rb +148 -0
- data/spec/operations/sequences/change_sequence_spec.rb +134 -0
- data/spec/operations/sequences/create_sequence_spec.rb +156 -0
- data/spec/operations/sequences/drop_sequence_spec.rb +102 -0
- data/spec/operations/sequences/rename_sequence_spec.rb +100 -0
- metadata +22 -68
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pg_trunk
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Andrew Kozin
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-01-
|
11
|
+
date: 2022-01-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -169,6 +169,17 @@ files:
|
|
169
169
|
- lib/pg_trunk/operations/procedures/create_procedure.rb
|
170
170
|
- lib/pg_trunk/operations/procedures/drop_procedure.rb
|
171
171
|
- lib/pg_trunk/operations/procedures/rename_procedure.rb
|
172
|
+
- lib/pg_trunk/operations/rules.rb
|
173
|
+
- lib/pg_trunk/operations/rules/base.rb
|
174
|
+
- lib/pg_trunk/operations/rules/create_rule.rb
|
175
|
+
- lib/pg_trunk/operations/rules/drop_rule.rb
|
176
|
+
- lib/pg_trunk/operations/rules/rename_rule.rb
|
177
|
+
- lib/pg_trunk/operations/sequences.rb
|
178
|
+
- lib/pg_trunk/operations/sequences/base.rb
|
179
|
+
- lib/pg_trunk/operations/sequences/change_sequence.rb
|
180
|
+
- lib/pg_trunk/operations/sequences/create_sequence.rb
|
181
|
+
- lib/pg_trunk/operations/sequences/drop_sequence.rb
|
182
|
+
- lib/pg_trunk/operations/sequences/rename_sequence.rb
|
172
183
|
- lib/pg_trunk/operations/statistics.rb
|
173
184
|
- lib/pg_trunk/operations/statistics/base.rb
|
174
185
|
- lib/pg_trunk/operations/statistics/create_statistics.rb
|
@@ -238,6 +249,13 @@ files:
|
|
238
249
|
- spec/operations/procedures/create_procedure_spec.rb
|
239
250
|
- spec/operations/procedures/drop_procedure_spec.rb
|
240
251
|
- spec/operations/procedures/rename_procedure_spec.rb
|
252
|
+
- spec/operations/rules/create_rule_spec.rb
|
253
|
+
- spec/operations/rules/drop_rule_spec.rb
|
254
|
+
- spec/operations/rules/rename_rule_spec.rb
|
255
|
+
- spec/operations/sequences/change_sequence_spec.rb
|
256
|
+
- spec/operations/sequences/create_sequence_spec.rb
|
257
|
+
- spec/operations/sequences/drop_sequence_spec.rb
|
258
|
+
- spec/operations/sequences/rename_sequence_spec.rb
|
241
259
|
- spec/operations/statistics/create_statistics_spec.rb
|
242
260
|
- spec/operations/statistics/drop_statistics_spec.rb
|
243
261
|
- spec/operations/statistics/rename_statistics_spec.rb
|
@@ -277,72 +295,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
277
295
|
- !ruby/object:Gem::Version
|
278
296
|
version: '0'
|
279
297
|
requirements: []
|
280
|
-
rubygems_version: 3.
|
298
|
+
rubygems_version: 3.1.6
|
281
299
|
signing_key:
|
282
300
|
specification_version: 4
|
283
301
|
summary: Empower PostgreSQL migrations in Rails app
|
284
|
-
test_files:
|
285
|
-
- spec/dummy/.gitignore
|
286
|
-
- spec/dummy/Rakefile
|
287
|
-
- spec/dummy/bin/bundle
|
288
|
-
- spec/dummy/bin/rails
|
289
|
-
- spec/dummy/bin/rake
|
290
|
-
- spec/dummy/config.ru
|
291
|
-
- spec/dummy/config/application.rb
|
292
|
-
- spec/dummy/config/boot.rb
|
293
|
-
- spec/dummy/config/database.yml
|
294
|
-
- spec/dummy/config/environment.rb
|
295
|
-
- spec/dummy/db/materialized_views/admin_users_v01.sql
|
296
|
-
- spec/dummy/db/migrate/.keep
|
297
|
-
- spec/dummy/db/schema.rb
|
298
|
-
- spec/dummy/db/views/admin_users_v01.sql
|
299
|
-
- spec/dummy/db/views/admin_users_v02.sql
|
300
|
-
- spec/operations/check_constraints/add_check_constraint_spec.rb
|
301
|
-
- spec/operations/check_constraints/drop_check_constraint_spec.rb
|
302
|
-
- spec/operations/check_constraints/rename_check_constraint_spec.rb
|
303
|
-
- spec/operations/composite_types/change_composite_type_spec.rb
|
304
|
-
- spec/operations/composite_types/create_composite_type_spec.rb
|
305
|
-
- spec/operations/composite_types/drop_composite_type_spec.rb
|
306
|
-
- spec/operations/composite_types/rename_composite_type_spec.rb
|
307
|
-
- spec/operations/dependency_resolver_spec.rb
|
308
|
-
- spec/operations/domains/change_domain_spec.rb
|
309
|
-
- spec/operations/domains/create_domain_spec.rb
|
310
|
-
- spec/operations/domains/drop_domain_spec.rb
|
311
|
-
- spec/operations/domains/rename_domain_spec.rb
|
312
|
-
- spec/operations/enums/change_enum_spec.rb
|
313
|
-
- spec/operations/enums/create_enum_spec.rb
|
314
|
-
- spec/operations/enums/drop_enum_spec.rb
|
315
|
-
- spec/operations/enums/rename_enum_spec.rb
|
316
|
-
- spec/operations/foreign_keys/add_foreign_key_spec.rb
|
317
|
-
- spec/operations/foreign_keys/drop_foreign_key_spec.rb
|
318
|
-
- spec/operations/foreign_keys/rename_foreign_key_spec.rb
|
319
|
-
- spec/operations/functions/change_function_spec.rb
|
320
|
-
- spec/operations/functions/create_function_spec.rb
|
321
|
-
- spec/operations/functions/drop_function_spec.rb
|
322
|
-
- spec/operations/functions/rename_function_spec.rb
|
323
|
-
- spec/operations/indexes/add_index_spec.rb
|
324
|
-
- spec/operations/materialized_views/change_materialized_view_spec.rb
|
325
|
-
- spec/operations/materialized_views/create_materialized_view_spec.rb
|
326
|
-
- spec/operations/materialized_views/drop_materialized_view_spec.rb
|
327
|
-
- spec/operations/materialized_views/refresh_materialized_view_spec.rb
|
328
|
-
- spec/operations/materialized_views/rename_materialized_view_spec.rb
|
329
|
-
- spec/operations/procedures/change_procedure_spec.rb
|
330
|
-
- spec/operations/procedures/create_procedure_spec.rb
|
331
|
-
- spec/operations/procedures/drop_procedure_spec.rb
|
332
|
-
- spec/operations/procedures/rename_procedure_spec.rb
|
333
|
-
- spec/operations/statistics/create_statistics_spec.rb
|
334
|
-
- spec/operations/statistics/drop_statistics_spec.rb
|
335
|
-
- spec/operations/statistics/rename_statistics_spec.rb
|
336
|
-
- spec/operations/tables/create_table_spec.rb
|
337
|
-
- spec/operations/tables/rename_table_spec.rb
|
338
|
-
- spec/operations/triggers/change_trigger_spec.rb
|
339
|
-
- spec/operations/triggers/create_trigger_spec.rb
|
340
|
-
- spec/operations/triggers/drop_trigger_spec.rb
|
341
|
-
- spec/operations/triggers/rename_trigger_spec.rb
|
342
|
-
- spec/operations/views/change_view_spec.rb
|
343
|
-
- spec/operations/views/create_view_spec.rb
|
344
|
-
- spec/operations/views/drop_view_spec.rb
|
345
|
-
- spec/operations/views/rename_view_spec.rb
|
346
|
-
- spec/pg_trunk/dependencies_resolver_spec.rb
|
347
|
-
- spec/spec_helper.rb
|
348
|
-
- spec/support/migrations_helper.rb
|
302
|
+
test_files: []
|