debug_logging 1.0.5 → 1.0.6

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6ede316640d9f7b8eab7f37ab76a16edaaf3d9ea
4
- data.tar.gz: 4b4c216a9bbf656dc70b24d4e5bfad0bc2cbb96e
3
+ metadata.gz: a7d2b010d394a66522b5a94e1a06010ee222e97b
4
+ data.tar.gz: 6a4b6aee82f818f482c71d5e3149dff8aefed907
5
5
  SHA512:
6
- metadata.gz: efb479b4bf74985818e13a891495a092aba9a24e999227a5848cd4ed47f603b12fea49342c5c290f36ef1fc0e6fc48c2e328c11b37dfce02eea56d608c8ada86
7
- data.tar.gz: eb6de008c1f9f55e868281c6772e73bdd7a65ecf3ee95b31702b2260acc9c48651a13ec6ac8c70ddbb02fa358162b6b7db90e647bfdee50f41ca6607af97e042
6
+ metadata.gz: 4136fbceadf5261fb3b67105029c5bca184c5f31320cc5ddd365b9afdab9f3c0663078a9bd70206aece0c98ee440b3566e297b3b580d1b9b97994aa1519535df
7
+ data.tar.gz: 7d952c4facfd037c474d469328ac6bcda239ddb8afcfcf6706d35c81ba13cc44ac53811b4e21cc8d4a306db3f3be3cbde1d3cf704f2e3d4e60081520e6ef15ea
data/.gitignore CHANGED
@@ -10,3 +10,4 @@
10
10
 
11
11
  # rspec failure tracking
12
12
  .rspec_status
13
+ .byebug_history
data/.travis.yml CHANGED
@@ -1,8 +1,9 @@
1
1
  sudo: false
2
2
  language: ruby
3
3
  rvm:
4
- - 2.1
5
- - 2.2
6
- - 2.3
7
- - 2.4.0
8
- before_install: gem install bundler -v 1.14.6
4
+ - ruby-2.1.10
5
+ - ruby-2.2.7
6
+ - ruby-2.3.4
7
+ - ruby-2.4.1
8
+ - jruby-9.1.5.0
9
+ before_install: gem install bundler -v 1.15.4
data/README.md CHANGED
@@ -127,7 +127,7 @@ class Car
127
127
 
128
128
  # For instance methods:
129
129
  # Option 2: add logging to all instance methods defined above (but *not* defined below)
130
- include DebugLogging::InstanceLogger.new(i_methods: debug_instance_methods(false))
130
+ include DebugLogging::InstanceLogger.new(i_methods: self.instance_methods(false))
131
131
 
132
132
  # override options for any instance method(s)
133
133
  include DebugLogging::InstanceLogger.new(i_methods: [:stop], config: { multiple_last_hashes: true })
@@ -10,7 +10,10 @@ Gem::Specification.new do |spec|
10
10
  spec.email = ["peter.boling@gmail.com"]
11
11
 
12
12
  spec.summary = %q{Drop-in debug logging useful when a call stack gets unruly}
13
- spec.description = %q{Automatically log Class.method(arguments) as they are called at runtime!}
13
+ spec.description = %q{
14
+ Unobtrusive debug logging for Ruby without the litter
15
+ Automatically log selected methods and their arguments as they are called at runtime!
16
+ }
14
17
  spec.homepage = "https://github.com/pboling/debug_logging"
15
18
 
16
19
  spec.files = `git ls-files -z`.split("\x0").reject do |f|
@@ -1,3 +1,3 @@
1
1
  module DebugLogging
2
- VERSION = "1.0.5"
2
+ VERSION = "1.0.6"
3
3
  end
data/lib/debug_logging.rb CHANGED
@@ -44,7 +44,7 @@ require "debug_logging/class_logger"
44
44
  #
45
45
  # # For instance methods:
46
46
  # # Option 2: add logging to all instance methods defined above (but *not* defined below)
47
- # include DebugLogging::InstanceLogger.new(i_methods: debug_instance_methods(false))
47
+ # include DebugLogging::InstanceLogger.new(i_methods: self.instance_methods(false))
48
48
  #
49
49
  # def will_not_be_logged; false; end
50
50
  #
@@ -61,7 +61,7 @@ module DebugLogging
61
61
  #### API ####
62
62
  def debug_log(message, config_proxy = nil)
63
63
  config_proxy ||= self
64
- config_proxy.debug_logger.send(config_proxy.debug_log_level, message)
64
+ config_proxy.debug_logger.send(config_proxy.debug_log_level, message) if config_proxy.debug_logger
65
65
  end
66
66
 
67
67
  # There are times when the class will need access to the configuration object,
@@ -13,6 +13,7 @@ class SimpleDebugLogging < Module
13
13
  def included(base)
14
14
  instance_method_logger = InstanceMethodLoggerModulizer.to_mod(@instance_methods_to_log)
15
15
  base.send(:prepend, instance_method_logger)
16
+ base.send(:extend, ClassMethodLogger)
16
17
  end
17
18
  module ClassMethodLogger
18
19
  def logged(*methods_to_log)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: debug_logging
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.5
4
+ version: 1.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Peter Boling
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-03-31 00:00:00.000000000 Z
11
+ date: 2017-09-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: colorize
@@ -94,14 +94,16 @@ dependencies:
94
94
  - - "~>"
95
95
  - !ruby/object:Gem::Version
96
96
  version: '3.0'
97
- description: Automatically log Class.method(arguments) as they are called at runtime!
97
+ description: |2
98
+
99
+ Unobtrusive debug logging for Ruby without the litter
100
+ Automatically log selected methods and their arguments as they are called at runtime!
98
101
  email:
99
102
  - peter.boling@gmail.com
100
103
  executables: []
101
104
  extensions: []
102
105
  extra_rdoc_files: []
103
106
  files:
104
- - ".byebug_history"
105
107
  - ".gitignore"
106
108
  - ".rspec"
107
109
  - ".travis.yml"
@@ -138,7 +140,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
138
140
  version: '0'
139
141
  requirements: []
140
142
  rubyforge_project:
141
- rubygems_version: 2.6.11
143
+ rubygems_version: 2.6.12
142
144
  signing_key:
143
145
  specification_version: 4
144
146
  summary: Drop-in debug logging useful when a call stack gets unruly
data/.byebug_history DELETED
@@ -1,7 +0,0 @@
1
- exit
2
- config_proxy
3
- config
4
- exit
5
- @debug_logging_configuration
6
- debug_logging_configuration
7
- debug_class_benchmarks