devkitkat 0.1.18 → 0.1.20
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.gitignore +1 -0
- data/Gemfile.lock +2 -2
- data/bin/devkitkat +1 -0
- data/lib/devkitkat/command.rb +16 -8
- data/lib/devkitkat/main.rb +8 -2
- data/lib/devkitkat/service.rb +1 -0
- data/lib/devkitkat/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: fc4e89605c7399f9d0552458cc97d8537427bac842b6914583fd387c3c5f38bc
|
4
|
+
data.tar.gz: 75e49494c401224ac04c7437c4cc6054444647370a226ce6d1e53c86beb83414
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3ef8f4df847e466f3d33a4731a42d5537c6a2081a0e98e0ced285e92dc053ded777237fb7846d445bb5bbfb58f340c0418e042e194e8744eae1684f09d188a25
|
7
|
+
data.tar.gz: 04a41c6e24be0eed4b17dd559a2335dfd76f8641444cb07d1ca990819f3d3d5086a6ae94b030592aa4f7fdda8f4fb0c9a75f90a795c26bd195ea93ac8ce36c98
|
data/.gitignore
CHANGED
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
devkitkat (0.1.
|
4
|
+
devkitkat (0.1.20)
|
5
5
|
activesupport (~> 6.0.0)
|
6
6
|
colorize (~> 0.8.1)
|
7
7
|
docker-api (~> 1.34.2)
|
@@ -26,7 +26,7 @@ GEM
|
|
26
26
|
docker-api (1.34.2)
|
27
27
|
excon (>= 0.47.0)
|
28
28
|
multi_json
|
29
|
-
excon (0.
|
29
|
+
excon (0.68.0)
|
30
30
|
i18n (1.7.0)
|
31
31
|
concurrent-ruby (~> 1.0)
|
32
32
|
method_source (0.9.2)
|
data/bin/devkitkat
CHANGED
data/lib/devkitkat/command.rb
CHANGED
@@ -24,6 +24,10 @@ module Devkitkat
|
|
24
24
|
options[:debug]
|
25
25
|
end
|
26
26
|
|
27
|
+
def quiet?
|
28
|
+
options[:quiet]
|
29
|
+
end
|
30
|
+
|
27
31
|
def tmp_dir
|
28
32
|
File.join(kit_root, '.devkitkat')
|
29
33
|
end
|
@@ -44,8 +48,8 @@ module Devkitkat
|
|
44
48
|
opts.separator ""
|
45
49
|
opts.separator "Options:"
|
46
50
|
|
47
|
-
opts.on("-
|
48
|
-
options[:
|
51
|
+
opts.on("-d", "--debug", "Debug mode") do |v|
|
52
|
+
options[:debug] = v
|
49
53
|
end
|
50
54
|
|
51
55
|
opts.on("-e", "--exclude SERVICE", "Exclude serviced from the specified target") do |v|
|
@@ -58,23 +62,27 @@ module Devkitkat
|
|
58
62
|
options[:variables].merge!(Hash[*v.split('=')])
|
59
63
|
end
|
60
64
|
|
61
|
-
opts.on("-
|
62
|
-
|
65
|
+
opts.on("-h", "--help", "Show help") do |v|
|
66
|
+
show_help
|
63
67
|
end
|
64
68
|
|
65
69
|
opts.on("-i", "--interactive", "Interactive mode. STDOUT is streamed in console.") do |v|
|
66
70
|
options[:interactive] = v
|
67
71
|
end
|
68
72
|
|
73
|
+
opts.on("-p", "--path PATH", "The root path of the .devkitkat.yml") do |v|
|
74
|
+
options[:root_path] = v
|
75
|
+
end
|
76
|
+
|
77
|
+
opts.on("-q", "--quiet", 'Quiet mode') do |v|
|
78
|
+
options[:quiet] = v
|
79
|
+
end
|
80
|
+
|
69
81
|
opts.on("-v", "--version", "Show version") do |v|
|
70
82
|
puts Devkitkat::VERSION
|
71
83
|
exit
|
72
84
|
end
|
73
85
|
|
74
|
-
opts.on("-h", "--help", "Show help") do |v|
|
75
|
-
show_help
|
76
|
-
end
|
77
|
-
|
78
86
|
opts.separator ""
|
79
87
|
opts.separator "Utility Commands:"
|
80
88
|
opts.separator "add-script - Add a script file"
|
data/lib/devkitkat/main.rb
CHANGED
@@ -24,18 +24,24 @@ module Devkitkat
|
|
24
24
|
end
|
25
25
|
end
|
26
26
|
|
27
|
-
|
27
|
+
terminate_process_group! unless results&.all? { |result| result == true }
|
28
28
|
end
|
29
29
|
|
30
30
|
private
|
31
31
|
|
32
|
+
def terminate_process_group!
|
33
|
+
pgid = Process.getpgid(Process.pid)
|
34
|
+
|
35
|
+
Process.kill('TERM', -pgid)
|
36
|
+
end
|
37
|
+
|
32
38
|
def target_services
|
33
39
|
@target_services ||= config.resolve!(command.target, exclude: command.options[:exclude])
|
34
40
|
.map { |name| Service.new(name, config, command) }
|
35
41
|
end
|
36
42
|
|
37
43
|
def print_log_paths
|
38
|
-
return if command.interactive?
|
44
|
+
return if command.interactive? || command.quiet?
|
39
45
|
|
40
46
|
log_paths = target_services.map(&:log_path)
|
41
47
|
puts %Q{See the log at \n#{log_paths.join("\n")}}
|
data/lib/devkitkat/service.rb
CHANGED
data/lib/devkitkat/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: devkitkat
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.20
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Shinya Maeda
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-10-
|
11
|
+
date: 2019-10-27 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|