composite_logger 1.0.0 → 1.1.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/README.md +2 -2
- data/lib/composite_logger.rb +4 -4
- 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: 94e99b1affa95a055bb3b327a2f4beb21c0e2b4e
|
4
|
+
data.tar.gz: 3e29dc2b324016aa1d58e1f6bc98874d13ff8898
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e0dcb481420b18991bc063f80c04fc7ae659945030466031f946634ab2729f2ea954ea971407596d652179bf79572ead81f433d2c8a3ee6a7d64663dae88958e
|
7
|
+
data.tar.gz: a8a1f1d501772f324d8a084174a156be24577f7a2d145b16e7e8e9d2df99a3322cb6c23cce718244d2272950539602abb6ecc363f324715c0c3813648b774d33
|
data/README.md
CHANGED
@@ -9,7 +9,7 @@ TODO: Delete this and the text above, and describe your gem
|
|
9
9
|
Add this line to your application's Gemfile:
|
10
10
|
|
11
11
|
```ruby
|
12
|
-
gem
|
12
|
+
gem "composite_logger"
|
13
13
|
```
|
14
14
|
|
15
15
|
And then execute:
|
@@ -32,7 +32,7 @@ To install this gem onto your local machine, run `bundle exec rake install`. To
|
|
32
32
|
|
33
33
|
## Contributing
|
34
34
|
|
35
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
35
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/fertapric/composite_logger. This project is intended to be a safe, welcoming space for collaboration, and contributors are expected to adhere to the [Contributor Covenant](contributor-covenant.org) code of conduct.
|
36
36
|
|
37
37
|
|
38
38
|
## License
|
data/lib/composite_logger.rb
CHANGED
@@ -3,7 +3,7 @@ require "logger"
|
|
3
3
|
class CompositeLogger < Logger
|
4
4
|
VERSION = [
|
5
5
|
VERSION_MAJOR = 1,
|
6
|
-
VERSION_MINOR =
|
6
|
+
VERSION_MINOR = 1,
|
7
7
|
VERSION_TINY = 0,
|
8
8
|
VERSION_PRE = nil
|
9
9
|
].compact.join(".")
|
@@ -38,8 +38,8 @@ class CompositeLogger < Logger
|
|
38
38
|
@loggers ||= []
|
39
39
|
end
|
40
40
|
|
41
|
-
def <<(
|
42
|
-
loggers
|
41
|
+
def <<(logger)
|
42
|
+
loggers << logger
|
43
43
|
end
|
44
44
|
|
45
45
|
def add(severity, message = nil, progname = nil, &block)
|
@@ -47,6 +47,6 @@ class CompositeLogger < Logger
|
|
47
47
|
|
48
48
|
return true if severity < @level
|
49
49
|
|
50
|
-
loggers.
|
50
|
+
loggers.map { |logger| logger.add(severity, message, progname, &block) }
|
51
51
|
end
|
52
52
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: composite_logger
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Fernando Tapia Rico
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-08-
|
11
|
+
date: 2015-08-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -52,7 +52,7 @@ dependencies:
|
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '5.8'
|
55
|
-
description: One log to rule them all. Log using multiple
|
55
|
+
description: One log to rule them all. Log using multiple Logger instances.
|
56
56
|
email:
|
57
57
|
- fertapric@gmail.com
|
58
58
|
executables: []
|