avm-eac_postgresql_base0 0.3.0 → 0.4.0
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 87fd0b8fc37e185451163ffce33b07b4e9dae7ac8a4c9b0e8b9b345abe31bd92
|
4
|
+
data.tar.gz: aa7ca433255e681a839e3d66f94b3cc15f59316aa5358f1d342c1068bc1c6ea4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 79a4baf2e58a6d56b7046badcc10a8b6d2456f2e42c459c8356668942fa104f256d18f3a80996a54bc8f706624be4b6e21002871e83632119165903bb55fca5c
|
7
|
+
data.tar.gz: f73ad27f21f5a99fb84782504b891e20f3f659cbea4c4afc793709f37c855c25f46ba20158524811623e7980ecac5e608836ae92858270381115c0fec6e362d5
|
@@ -12,7 +12,18 @@ module Avm
|
|
12
12
|
TABLES_SQL = "select schemaname || '#{TABLE_PARTS_SEPARATOR}' || tablename from " \
|
13
13
|
"pg_tables where schemaname = '#{SCHEMA_VAR}'"
|
14
14
|
|
15
|
-
before_load :
|
15
|
+
before_load :clear
|
16
|
+
|
17
|
+
def clear
|
18
|
+
info 'Clearing database (Dropping all tables)...'
|
19
|
+
ts = tables
|
20
|
+
if ts.empty?
|
21
|
+
info 'Database has no tables'
|
22
|
+
else
|
23
|
+
info "Removing #{ts.count} table(s)..."
|
24
|
+
run_sql(drop_tables_sql(ts))
|
25
|
+
end
|
26
|
+
end
|
16
27
|
|
17
28
|
def dump_command
|
18
29
|
instance.dump_gzip_command
|
@@ -30,17 +41,6 @@ module Avm
|
|
30
41
|
'drop table ' + table_list.map(&:to_s).join(', ') + ' cascade'
|
31
42
|
end
|
32
43
|
|
33
|
-
def clear_database
|
34
|
-
info 'Clearing database (Dropping all tables)...'
|
35
|
-
ts = tables
|
36
|
-
if ts.empty?
|
37
|
-
info 'Database has no tables'
|
38
|
-
else
|
39
|
-
info "Removing #{ts.count} table(s)..."
|
40
|
-
run_sql(drop_tables_sql(ts))
|
41
|
-
end
|
42
|
-
end
|
43
|
-
|
44
44
|
# @param parts [Array<String>, Strings]
|
45
45
|
# @return [String]
|
46
46
|
def join_table_parts(parts)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: avm-eac_postgresql_base0
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.4.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Put here the authors
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-05-
|
11
|
+
date: 2023-05-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: avm
|
@@ -16,42 +16,42 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '0.
|
19
|
+
version: '0.69'
|
20
20
|
type: :runtime
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '0.
|
26
|
+
version: '0.69'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: eac_ruby_utils
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '0.
|
33
|
+
version: '0.113'
|
34
34
|
type: :runtime
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '0.
|
40
|
+
version: '0.113'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: eac_ruby_gem_support
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 0.5.1
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 0.5.1
|
55
55
|
description:
|
56
56
|
email:
|
57
57
|
executables: []
|