loggability 0.9.0 → 0.10.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- checksums.yaml.gz.sig +0 -0
- data/History.rdoc +6 -0
- data/lib/loggability/logger.rb +8 -0
- data/lib/loggability.rb +2 -2
- data/spec/loggability/logger_spec.rb +10 -0
- data.tar.gz.sig +2 -3
- metadata +2 -2
- metadata.gz.sig +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bcfe7394dd583eb237c03b2b2a13bdc1d6a72de4
|
4
|
+
data.tar.gz: 1b76276780077d5cfe39e56f09021c72bde2fdff
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2250e5530507cf215f953fbbbc525d2fdb2d4e90c6fa8010bfd1edc1f75f926b2dd850e4fdaad81bd9effe684edd27ed0a009637e6d9f1da3515c2c82ae7677a
|
7
|
+
data.tar.gz: f95858f8e36057485c6e3b24f59bfd2cab013ab0c6a54b502da0a69ce6f0342a25c758b2b162899d2f2e441b91cbf707cfb0b101e56b118efac84cf12aedac99
|
checksums.yaml.gz.sig
CHANGED
Binary file
|
data/History.rdoc
CHANGED
data/lib/loggability/logger.rb
CHANGED
@@ -185,6 +185,14 @@ class Loggability::Logger < ::Logger
|
|
185
185
|
end
|
186
186
|
|
187
187
|
|
188
|
+
### Rack::CommonLogger compatibility method -- append a +message+ at 'info' level.
|
189
|
+
def write( message )
|
190
|
+
unless self.logdev.nil?
|
191
|
+
self.add( Logger::INFO, message )
|
192
|
+
end
|
193
|
+
end
|
194
|
+
|
195
|
+
|
188
196
|
### Return a Hash that contains its settings suitable for restoration via
|
189
197
|
### #restore_settings later.
|
190
198
|
def settings
|
data/lib/loggability.rb
CHANGED
@@ -9,10 +9,10 @@ require 'date'
|
|
9
9
|
module Loggability
|
10
10
|
|
11
11
|
# Package version constant
|
12
|
-
VERSION = '0.
|
12
|
+
VERSION = '0.10.0'
|
13
13
|
|
14
14
|
# VCS revision
|
15
|
-
REVISION = %q$Revision:
|
15
|
+
REVISION = %q$Revision: b1250807b56e $
|
16
16
|
|
17
17
|
# The key for the global logger (Loggability's own logger)
|
18
18
|
GLOBAL_KEY = :__global__
|
@@ -52,6 +52,16 @@ describe Loggability::Logger do
|
|
52
52
|
end
|
53
53
|
|
54
54
|
|
55
|
+
it "supports #write so it can be used with Rack::CommonLogger" do
|
56
|
+
results = []
|
57
|
+
@logger.level = :debug
|
58
|
+
@logger.output_to( results )
|
59
|
+
@logger.write( "This is a written message." )
|
60
|
+
|
61
|
+
expect( results.first ).to match( /info.*this is a written message/i )
|
62
|
+
end
|
63
|
+
|
64
|
+
|
55
65
|
it "can return a Hash of its current settings" do
|
56
66
|
expect( @logger.settings ).to be_a( Hash )
|
57
67
|
expect( @logger.settings ).to include( :level, :formatter, :logdev )
|
data.tar.gz.sig
CHANGED
@@ -1,3 +1,2 @@
|
|
1
|
-
|
2
|
-
|
3
|
-
@D����
|
1
|
+
���+��U��~�W�,D�P`ѰGzޡ��M"L'�O.��D���$=H����Kx�1��e@\B�r�2&Ş|G��7vJb����W��j��v" 0�.:tm�G�u�^M�l�]\�K�[�x�7�Z�!$�v;��3�<#h�����ٚ�a��{x��_���t��"���`$�nc*`G�B�
|
2
|
+
<��PH�Tm����2�p��q����� TU�د��MK�2P���Ćn�H��,���*�wlRs��
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: loggability
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.10.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Michael Granger
|
@@ -30,7 +30,7 @@ cert_chain:
|
|
30
30
|
6mKCwjpegytE0oifXfF8k75A9105cBnNiMZOe1tXiqYc/exCgWvbggurzDOcRkZu
|
31
31
|
/YSusaiDXHKU2O3Akc3htA==
|
32
32
|
-----END CERTIFICATE-----
|
33
|
-
date: 2014-
|
33
|
+
date: 2014-02-05 00:00:00.000000000 Z
|
34
34
|
dependencies:
|
35
35
|
- !ruby/object:Gem::Dependency
|
36
36
|
name: hoe-mercurial
|
metadata.gz.sig
CHANGED
Binary file
|