seed_dump 3.4.1 → 3.4.2
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/lib/seed_dump/environment.rb +19 -4
- 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: 86ebb337756312dfd0fb294d6fec80c9494d235efdf569e1f89185ff106f309b
|
|
4
|
+
data.tar.gz: 9995d223fc303375bcd2e254ea306c9c57e7eb966ba77e8a7f6f9cde878503d5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cd736b88f2e55212f51267ab1af7a5013c6aa463d8842cf78051eb6337a7e0ae6a46bd82f8e2fdcee432e98ef4cb12ce3660a7c5d5771345c850dcbc8759ccb9
|
|
7
|
+
data.tar.gz: 68f8a5c394ac6eab3e77fabbdd3b1657a5466d786d9e242b7c0b19319ab15b3afa402de0c6be8a0b197bfe7069001bc357cce3b00eb565d3a8e57ab41523eb21
|
|
@@ -258,11 +258,26 @@ class SeedDump
|
|
|
258
258
|
parse_boolean_value(env['APPEND'])
|
|
259
259
|
end
|
|
260
260
|
|
|
261
|
-
# Internal: Returns
|
|
262
|
-
#
|
|
263
|
-
#
|
|
261
|
+
# Internal: Returns true if the IMPORT env var enables bulk import.
|
|
262
|
+
#
|
|
263
|
+
# IMPORT may be:
|
|
264
|
+
# - "true" (case-insensitive)
|
|
265
|
+
# - A JSON hash of activerecord-import options (e.g. '{ "validate": false }')
|
|
266
|
+
#
|
|
267
|
+
# Returns false if IMPORT is unset or invalid.
|
|
264
268
|
def retrieve_import_value(env)
|
|
265
|
-
|
|
269
|
+
value = env['IMPORT']
|
|
270
|
+
return false if value.nil?
|
|
271
|
+
|
|
272
|
+
# Backward compatibility: IMPORT=true
|
|
273
|
+
return true if parse_boolean_value(value)
|
|
274
|
+
|
|
275
|
+
# New behavior: IMPORT is a JSON hash of options
|
|
276
|
+
begin
|
|
277
|
+
JSON.parse(value)
|
|
278
|
+
rescue JSON::ParserError
|
|
279
|
+
false
|
|
280
|
+
end
|
|
266
281
|
end
|
|
267
282
|
|
|
268
283
|
# Internal: Returns a Boolean indicating whether the value for the "INSERT_ALL"
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: seed_dump
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 3.4.
|
|
4
|
+
version: 3.4.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Rob Halff
|
|
@@ -9,7 +9,7 @@ authors:
|
|
|
9
9
|
autorequire:
|
|
10
10
|
bindir: bin
|
|
11
11
|
cert_chain: []
|
|
12
|
-
date:
|
|
12
|
+
date: 2026-05-13 00:00:00.000000000 Z
|
|
13
13
|
dependencies:
|
|
14
14
|
- !ruby/object:Gem::Dependency
|
|
15
15
|
name: activerecord
|