rbld-plugin-hello 0.0.2 → 0.0.3
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/rbld-plugin-hello.rb +29 -3
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a44e060f8590416e1c85d8535e1c9142b784ac54
|
4
|
+
data.tar.gz: 07c25cbde7eac6c2949b83d312063be6717301c4
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ab10e43373b8f6cbeeb63b94a1cbac2bb780f32b4eac1007ab21ed5ccd25121ee6c16c4d3a0c217d648b0be78f162ea6475faf96c4f762e6d76b16d903efc5eb
|
7
|
+
data.tar.gz: c319be1d74ff6938494b72f226939d43a982f8fd8d298c6a2c8eb4e73334e148f782caa5c33bc8131125dafbcf0151a0f74a5b3ac866db38a5148faa35159a52
|
data/lib/rbld-plugin-hello.rb
CHANGED
@@ -4,9 +4,35 @@ require 'plugman/plugin_base'
|
|
4
4
|
module RebuildPlugins
|
5
5
|
class HelloPlugin < Plugman::PluginBase
|
6
6
|
def start(stream = STDOUT)
|
7
|
-
stream
|
8
|
-
|
9
|
-
|
7
|
+
@stream = stream
|
8
|
+
|
9
|
+
banner( 'Hello from Rebuild CLI plugin' )
|
10
|
+
# yiedling means that plugin errored during this notification processing
|
11
|
+
# yield
|
12
|
+
end
|
13
|
+
|
14
|
+
def command(cmd_name, *args)
|
15
|
+
banner( "Hello from Rebuild CLI plugin known command #{cmd_to_s(cmd_name, args)} handler" )
|
16
|
+
# yiedling means that plugin errored during this notification processing
|
17
|
+
# yield
|
18
|
+
end
|
19
|
+
|
20
|
+
def unknown_command(cmd_name, *args)
|
21
|
+
banner( "Hello from Rebuild CLI plugin unknown command #{cmd_to_s(cmd_name, args)} handler" )
|
22
|
+
# yielding means that command was processed by this plugin
|
23
|
+
yield
|
24
|
+
end
|
25
|
+
|
26
|
+
private
|
27
|
+
|
28
|
+
def banner(msg)
|
29
|
+
@stream.puts
|
30
|
+
@stream.puts msg.green
|
31
|
+
@stream.puts
|
32
|
+
end
|
33
|
+
|
34
|
+
def cmd_to_s(name, args)
|
35
|
+
"#{name}(#{args.join( ', ' )})"
|
10
36
|
end
|
11
37
|
end
|
12
38
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rbld-plugin-hello
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dmitry Fleytman
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-
|
11
|
+
date: 2017-04-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: colorize
|
@@ -171,8 +171,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
171
171
|
version: '0'
|
172
172
|
requirements: []
|
173
173
|
rubyforge_project:
|
174
|
-
rubygems_version: 2.
|
174
|
+
rubygems_version: 2.6.11
|
175
175
|
signing_key:
|
176
176
|
specification_version: 4
|
177
|
-
summary: rbld-plugin-hello-0.0.
|
177
|
+
summary: rbld-plugin-hello-0.0.3
|
178
178
|
test_files: []
|