bmc-daemon-lib 0.4.3 → 0.5.0
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/Gemfile.lock +3 -3
- data/bmc-daemon-lib.gemspec +1 -1
- data/lib/bmc-daemon-lib/logger.rb +20 -6
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 16ae424ba8d0838d48068487ec6739acda76b75d
|
4
|
+
data.tar.gz: fc5235c44fc15208b7305d3872400ba3cee78cca
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b450c78b14f81ace23d7a06f51d62dd5b1715ab2b4d9c30777d2bac02bcaeb32a53dbe9852a2570d44bd3febd9582f6b5dae94e97c36ad3ed21a73eecdaebe92
|
7
|
+
data.tar.gz: f312782905efbecfd11c7403397913f80d0f2f38ce89ce28904d483c8b896c9c183c712e8b185d3814309315d29ba74ffb7152db3b3df922e58843e063268452
|
data/Gemfile.lock
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
bmc-daemon-lib (0.
|
4
|
+
bmc-daemon-lib (0.5.0)
|
5
5
|
chamber (~> 2.9.1)
|
6
6
|
|
7
7
|
GEM
|
@@ -17,7 +17,7 @@ GEM
|
|
17
17
|
rspec-core (~> 3.5.0)
|
18
18
|
rspec-expectations (~> 3.5.0)
|
19
19
|
rspec-mocks (~> 3.5.0)
|
20
|
-
rspec-core (3.5.
|
20
|
+
rspec-core (3.5.4)
|
21
21
|
rspec-support (~> 3.5.0)
|
22
22
|
rspec-expectations (3.5.0)
|
23
23
|
diff-lcs (>= 1.2.0, < 2.0)
|
@@ -38,4 +38,4 @@ DEPENDENCIES
|
|
38
38
|
rspec
|
39
39
|
|
40
40
|
BUNDLED WITH
|
41
|
-
1.
|
41
|
+
1.13.5
|
data/bmc-daemon-lib.gemspec
CHANGED
@@ -45,15 +45,29 @@ module BmcDaemonLib
|
|
45
45
|
messages = []
|
46
46
|
messages << sprintf(@format[:text], message) if message
|
47
47
|
|
48
|
+
# Add raw lines
|
49
|
+
if context.nil? && (details.is_a? Array)
|
50
|
+
messages = details
|
51
|
+
|
48
52
|
# Add details from array
|
49
|
-
details.
|
50
|
-
|
51
|
-
|
53
|
+
elsif details.is_a? Array
|
54
|
+
details.each do |line|
|
55
|
+
messages << sprintf(@format[:array], line)
|
56
|
+
end
|
52
57
|
|
53
58
|
# Add details from hash
|
54
|
-
details.
|
55
|
-
|
56
|
-
|
59
|
+
elsif details.is_a? Hash
|
60
|
+
details.each do |key, value|
|
61
|
+
messages << sprintf(@format[:hash], key, value)
|
62
|
+
end
|
63
|
+
|
64
|
+
# Add each line of "details" after split
|
65
|
+
elsif details.is_a? String
|
66
|
+
details.lines.each do |line|
|
67
|
+
messages << line unless line.empty?
|
68
|
+
end
|
69
|
+
|
70
|
+
end
|
57
71
|
|
58
72
|
# Pass all that stuff to my parent
|
59
73
|
super severity, messages, context
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bmc-daemon-lib
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Bruno MEDICI
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-10-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -108,7 +108,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
108
108
|
version: '0'
|
109
109
|
requirements: []
|
110
110
|
rubyforge_project:
|
111
|
-
rubygems_version: 2.
|
111
|
+
rubygems_version: 2.5.1
|
112
112
|
signing_key:
|
113
113
|
specification_version: 4
|
114
114
|
summary: 'Shared utilities to build a daemon: logger, configuration, helpers'
|