sct 1.0.9 → 1.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/sct/lib/sct/commands/databasepull.rb +21 -8
- data/sct/lib/sct/commands_generator.rb +1 -0
- data/sct/lib/sct/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: 8fad01fe00c948d248dae7390285021760ae28ad592411a3cbc18ffdef650cd8
|
4
|
+
data.tar.gz: 1ba8d43b23ade6f4316767b8759c91bf98f2dac1327cb9903a2c8fa66b2f7a5e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 88c67f14fb87bc1ca891527e46b78b7552fb5021832347fdff73e4af0a8066e6b25cd17344b295ba2588af7265682a79248b245d6d2f0b1fe93fa5e9d5b4050c
|
7
|
+
data.tar.gz: 392db33f0c88bdc2f36025b24a85614865bcf54d99f22970b8da874bf8abf1f956ec194ab5dc3d2659ee708fc5d34940d59689d6f2e0e9bf433139c3262dd5d0
|
@@ -23,14 +23,27 @@ module Sct
|
|
23
23
|
error "Private token not set"
|
24
24
|
end
|
25
25
|
|
26
|
-
if options.
|
27
|
-
UI.important("Requesting to pull database for proactive frame")
|
28
|
-
process_request = `curl -X POST -F token=#{private_token} -F ref=master -F variables[DB_PULL_FRAME]=true -F variables[REMOTE_BRANCH_NAME]=#{branch} #{pipeline_endpoint}`
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
26
|
+
if options.all
|
27
|
+
UI.important("Requesting to pull database changes for proactive frame and proactive config")
|
28
|
+
process_request = `curl -X POST -F token=#{private_token} -F ref=master -F variables[DB_PULL_FRAME]=true -F variables[DB_PULL_CONFIG]=true -F variables[REMOTE_BRANCH_NAME]=#{branch} #{pipeline_endpoint}`
|
29
|
+
else
|
30
|
+
db_pull_frame = ""
|
31
|
+
if options.proactive_frame
|
32
|
+
UI.important("Requesting to pull database for proactive frame")
|
33
|
+
db_pull_frame = "-F variables[DB_PULL_FRAME]=true"
|
34
|
+
end
|
35
|
+
|
36
|
+
db_pull_config = ""
|
37
|
+
if options.proactive_config
|
38
|
+
UI.important("Requesting to pull database for proactive config")
|
39
|
+
db_pull_config = "-F variables[DB_PULL_CONFIG]=true"
|
40
|
+
end
|
41
|
+
|
42
|
+
if db_pull_frame != "" or db_pull_config != ""
|
43
|
+
process_request = `curl -X POST -F token=#{private_token} -F ref=master #{db_pull_frame} #{db_pull_config} -F variables[REMOTE_BRANCH_NAME]=#{branch} #{pipeline_endpoint}`
|
44
|
+
else
|
45
|
+
error "Missing options. Use --help to see the available options"
|
46
|
+
end
|
34
47
|
end
|
35
48
|
end
|
36
49
|
end
|
@@ -57,6 +57,7 @@ module Sct
|
|
57
57
|
command :'database-pull' do |c|
|
58
58
|
c.syntax = 'sct database pull'
|
59
59
|
c.description = 'pull database changes for proactive frame and proactive config'
|
60
|
+
c.option '--all', 'pull the database changes for all repositories'
|
60
61
|
c.option '--proactive-frame', 'pull the database changes from proactive-frame'
|
61
62
|
c.option '--proactive-config', 'pull the database changes from proactive-config'
|
62
63
|
|
data/sct/lib/sct/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: sct
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Reshad Farid
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-06-
|
11
|
+
date: 2021-06-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colored
|