pg_objects 1.3.0 → 1.3.1
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/Gemfile.lock +6 -6
- data/README.md +10 -10
- data/lib/pg_objects/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 46968edaefe0dd460b86f65907df0da5e698f775713d2174ee3f353ed844ce78
|
4
|
+
data.tar.gz: c5e7a825fba2451b16369e6690114e9a7d9bee79d3ccf76b448ee06dc0c02ee7
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3b22eba8c6739aa46603b1226aa22d8a44b032c9ba64546c52c84b9bdd3ff84abd519029bdb1d4d1360a8dd8cfa755c661f6a68da0d6b53f62f0e00bbe7ad76b
|
7
|
+
data.tar.gz: d1219118bf8574b91372554594d7cd36afc7dc7771d6e0ded70764e2db92f0a221093f5a0ba4321d6c6ada7dfb491e6e37ff12c3d305d2f6ece13e8c4d21cbcc
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
pg_objects (1.3.
|
4
|
+
pg_objects (1.3.1)
|
5
5
|
activerecord (>= 6.1.7.0, < 8)
|
6
6
|
dry-auto_inject (~> 1)
|
7
7
|
dry-configurable (~> 1)
|
@@ -117,7 +117,7 @@ GEM
|
|
117
117
|
nokogiri (1.16.5-x86_64-linux)
|
118
118
|
racc (~> 1.4)
|
119
119
|
parallel (1.25.1)
|
120
|
-
parser (3.3.
|
120
|
+
parser (3.3.4.0)
|
121
121
|
ast (~> 2.4.1)
|
122
122
|
racc
|
123
123
|
pg_query (5.1.0)
|
@@ -167,7 +167,7 @@ GEM
|
|
167
167
|
regexp_parser (2.9.2)
|
168
168
|
reline (0.5.7)
|
169
169
|
io-console (~> 0.5)
|
170
|
-
rexml (3.3.
|
170
|
+
rexml (3.3.2)
|
171
171
|
strscan
|
172
172
|
rspec (3.13.0)
|
173
173
|
rspec-core (~> 3.13.0)
|
@@ -193,13 +193,13 @@ GEM
|
|
193
193
|
binding_of_caller
|
194
194
|
rspec-parameterized-core (< 2)
|
195
195
|
rspec-support (3.13.1)
|
196
|
-
rubocop (1.
|
196
|
+
rubocop (1.65.0)
|
197
197
|
json (~> 2.3)
|
198
198
|
language_server-protocol (>= 3.17.0)
|
199
199
|
parallel (~> 1.10)
|
200
200
|
parser (>= 3.3.0.2)
|
201
201
|
rainbow (>= 2.2.2, < 4.0)
|
202
|
-
regexp_parser (>=
|
202
|
+
regexp_parser (>= 2.4, < 3.0)
|
203
203
|
rexml (>= 3.2.5, < 4.0)
|
204
204
|
rubocop-ast (>= 1.31.1, < 2.0)
|
205
205
|
ruby-progressbar (~> 1.7)
|
@@ -213,7 +213,7 @@ GEM
|
|
213
213
|
rubocop-ast (>= 1.31.1, < 2.0)
|
214
214
|
rubocop-rake (0.6.0)
|
215
215
|
rubocop (~> 1.0)
|
216
|
-
rubocop-rspec (3.0.
|
216
|
+
rubocop-rspec (3.0.3)
|
217
217
|
rubocop (~> 1.61)
|
218
218
|
ruby-progressbar (1.13.0)
|
219
219
|
ruby2_keywords (0.0.5)
|
data/README.md
CHANGED
@@ -18,7 +18,7 @@ gem 'pg_objects'
|
|
18
18
|
And then execute:
|
19
19
|
|
20
20
|
```shell
|
21
|
-
bundle
|
21
|
+
bundle install
|
22
22
|
```
|
23
23
|
|
24
24
|
Or install it yourself as:
|
@@ -35,9 +35,9 @@ bundle exec rails generate pg_objects:install
|
|
35
35
|
|
36
36
|
## Usage
|
37
37
|
|
38
|
-
|
38
|
+
Store DB objects as CREATE (or CREATE OR UPDATE) queries in files within a directory structure (default: *db/objects*).
|
39
39
|
|
40
|
-
You can control order of
|
40
|
+
You can control the order of creation by using the directive *depends_on* in an SQL comment:
|
41
41
|
|
42
42
|
```sql
|
43
43
|
--!depends_on my_another_func
|
@@ -45,14 +45,14 @@ CREATE FUNCTION my_func()
|
|
45
45
|
...
|
46
46
|
```
|
47
47
|
|
48
|
-
The string after directive should be
|
48
|
+
The string after the directive should be the name of the file that the dependency refers to, without the file extension.
|
49
49
|
|
50
50
|
## Configuration
|
51
51
|
|
52
|
-
You
|
52
|
+
You have the option to configure the gem using either a YAML file or a Ruby initializer. The priority order for configuration is as follows:
|
53
53
|
1. Ruby initializer
|
54
|
-
|
55
|
-
|
54
|
+
2. YAML config
|
55
|
+
3. Default values
|
56
56
|
|
57
57
|
### YAML
|
58
58
|
|
@@ -77,7 +77,7 @@ silent: false
|
|
77
77
|
|
78
78
|
### Initializer
|
79
79
|
|
80
|
-
Create file in *config/initializers* with the following content:
|
80
|
+
Create file in *config/initializers* directory with the following content:
|
81
81
|
|
82
82
|
```ruby
|
83
83
|
PgObjects.configure do |config|
|
@@ -88,9 +88,9 @@ PgObjects.configure do |config|
|
|
88
88
|
end
|
89
89
|
```
|
90
90
|
|
91
|
-
Otherwise default values will be used.
|
91
|
+
Otherwise, the default values will be used.
|
92
92
|
|
93
|
-
|
93
|
+
Please make sure to verify that the specified directories actually exist.
|
94
94
|
|
95
95
|
## Development
|
96
96
|
|
data/lib/pg_objects/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pg_objects
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.3.
|
4
|
+
version: 1.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Denis Kiselyov
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-07-
|
11
|
+
date: 2024-07-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|