lager 1.1.2.1 → 1.1.3.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 64b64cc70e40a568fafd57dd3734138c27f60110
4
+ data.tar.gz: a3a04e2ccd0fbd5e3353b4d6bb8319c1fe3bec09
5
+ SHA512:
6
+ metadata.gz: 0867774d99d08023b09b4c823d41939197f9b74b12e3ee585e0d809aae12dc143172bb8a6b68d9d0590ec905a993e3a73b847e3fa7dee9983bf3017f30fa12fe
7
+ data.tar.gz: 0346d4b317fe7914666fb35fa4676b97600bd82509c92fedab6b48e1191d7def7401cf01153a41144022efa6c641b1dfeb86f6bdd95362a004b5254137f2791f
data/README.md CHANGED
@@ -85,13 +85,10 @@ For Logger, generally: use block invocation of message methods.
85
85
  @lager.debug { "hi" }
86
86
  # rather than
87
87
  @lager.debug "hi"
88
-
89
- # By using the first form, the block will not be evaluated unless we
90
- # are logging at DEBUG level.
91
- # If using the second form, the message is evaluated no matter the current
92
- # log level. This can be significant when logging complicated messages.
93
88
  ```
94
89
 
90
+ By using the first form, the block will not be evaluated unless you are logging at DEBUG level. If using the second form, the message is evaluated no matter the current log level. This can be significant when logging heavily processed messages.
91
+
95
92
  Artifacts
96
93
  ---------
97
94
  * By mixing in Lager via extend, you introduce these class methods:
@@ -0,0 +1,12 @@
1
+ require 'buildar'
2
+ require 'rake/testtask'
3
+
4
+ Buildar.new do |b|
5
+ b.gemspec_file = 'lager.gemspec'
6
+ b.version_file = 'VERSION'
7
+ b.use_git = true
8
+ end
9
+
10
+ Rake::TestTask.new :test do |t|
11
+ t.pattern = 'test/*.rb'
12
+ end
data/VERSION CHANGED
@@ -1 +1 @@
1
- 1.1.2.1
1
+ 1.1.3.1
@@ -7,15 +7,22 @@ Gem::Specification.new do |s|
7
7
  s.has_rdoc = true
8
8
  s.description = "Should you use it? Yes."
9
9
 
10
- s.add_development_dependency "minitest", [">= 0"]
11
- s.add_development_dependency "buildar", ["~> 1.4"]
10
+ s.add_development_dependency "minitest", ["~> 1"]
11
+ s.add_development_dependency "buildar", ["~> 1"]
12
12
 
13
13
  # dynamic setup
14
14
  this_dir = File.expand_path('..', __FILE__)
15
15
  version_file = File.join(this_dir, 'VERSION')
16
- manifest_file = File.join(this_dir, 'MANIFEST.txt')
17
16
 
18
17
  # dynamic assignments
19
18
  s.version = File.read(version_file).chomp
20
- s.files = File.readlines(manifest_file).map { |f| f.chomp }
19
+ s.files = %w[lager.gemspec
20
+ VERSION
21
+ README.md
22
+ Rakefile
23
+ lib/lager.rb
24
+ test/lager.rb
25
+ examples/foo.rb
26
+ examples/usage.rb
27
+ ]
21
28
  end
@@ -54,15 +54,15 @@ module Lager
54
54
  dest # don't expose @lager here
55
55
  end
56
56
 
57
- # call without argument to get the log level
58
- # call with argument to set the log level
59
- # :debug, 'debug', and Logger::DEBUG (0) are all supported
57
+ # returns a symbol e.g. :debug -- possibly :unknown
60
58
  #
61
59
  def log_level
62
60
  raise "no @lager available" unless defined?(@lager)
63
61
  [:debug, :info, :warn, :error, :fatal][@lager.level] || :unknown
64
62
  end
65
63
 
64
+ # :debug, 'debug', and Logger::DEBUG (0) are all supported
65
+ #
66
66
  def log_level=(level)
67
67
  raise "no @lager available" unless defined?(@lager)
68
68
  case level
@@ -87,7 +87,7 @@ module Lager
87
87
  # typically only used within initialize
88
88
  #
89
89
  def lager
90
- log_to unless defined?(@lager)
90
+ raise "no @lager available" unless defined?(@lager)
91
91
  @lager
92
92
  end
93
93
  end
@@ -23,7 +23,7 @@ describe Lager do
23
23
  Foo.lager.must_be_instance_of(Logger)
24
24
  end
25
25
 
26
- it "must return nil" do
26
+ it "must return its argument" do
27
27
  Foo.log_to($stdout).must_equal $stdout
28
28
  end
29
29
 
metadata CHANGED
@@ -1,86 +1,79 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: lager
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.2.1
5
- prerelease:
4
+ version: 1.1.3.1
6
5
  platform: ruby
7
6
  authors:
8
7
  - Rick Hull
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-07-10 00:00:00.000000000 Z
11
+ date: 2014-11-30 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: minitest
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
- - - ! '>='
17
+ - - "~>"
20
18
  - !ruby/object:Gem::Version
21
- version: '0'
19
+ version: '1'
22
20
  type: :development
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
- - - ! '>='
24
+ - - "~>"
28
25
  - !ruby/object:Gem::Version
29
- version: '0'
26
+ version: '1'
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: buildar
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
- - - ~>
31
+ - - "~>"
36
32
  - !ruby/object:Gem::Version
37
- version: '1.4'
33
+ version: '1'
38
34
  type: :development
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
- - - ~>
38
+ - - "~>"
44
39
  - !ruby/object:Gem::Version
45
- version: '1.4'
40
+ version: '1'
46
41
  description: Should you use it? Yes.
47
42
  email:
48
43
  executables: []
49
44
  extensions: []
50
45
  extra_rdoc_files: []
51
46
  files:
52
- - lager.gemspec
53
- - MANIFEST.txt
54
- - VERSION
55
47
  - README.md
56
- - rakefile.rb
57
- - lib/lager.rb
58
- - test/lager.rb
48
+ - Rakefile
49
+ - VERSION
59
50
  - examples/foo.rb
60
51
  - examples/usage.rb
52
+ - lager.gemspec
53
+ - lib/lager.rb
54
+ - test/lager.rb
61
55
  homepage: http://github.com/rickhull/lager
62
56
  licenses:
63
57
  - LGPL
58
+ metadata: {}
64
59
  post_install_message:
65
60
  rdoc_options: []
66
61
  require_paths:
67
62
  - lib
68
63
  required_ruby_version: !ruby/object:Gem::Requirement
69
- none: false
70
64
  requirements:
71
- - - ! '>='
65
+ - - ">="
72
66
  - !ruby/object:Gem::Version
73
67
  version: '0'
74
68
  required_rubygems_version: !ruby/object:Gem::Requirement
75
- none: false
76
69
  requirements:
77
- - - ! '>='
70
+ - - ">="
78
71
  - !ruby/object:Gem::Version
79
72
  version: '0'
80
73
  requirements: []
81
74
  rubyforge_project:
82
- rubygems_version: 1.8.23
75
+ rubygems_version: 2.2.2
83
76
  signing_key:
84
- specification_version: 3
77
+ specification_version: 4
85
78
  summary: Sane class-level logging
86
79
  test_files: []
@@ -1,9 +0,0 @@
1
- lager.gemspec
2
- MANIFEST.txt
3
- VERSION
4
- README.md
5
- rakefile.rb
6
- lib/lager.rb
7
- test/lager.rb
8
- examples/foo.rb
9
- examples/usage.rb
@@ -1,14 +0,0 @@
1
- require 'buildar/tasks'
2
- require 'rake/testtask'
3
-
4
- Buildar.conf(__FILE__) do |b|
5
- b.name = 'lager'
6
- b.use_version_file = true
7
- b.version_filename = 'VERSION'
8
- b.use_git = true
9
- b.publish[:rubygems] = true
10
- end
11
-
12
- Rake::TestTask.new :test do |t|
13
- t.pattern = 'test/*.rb'
14
- end