Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Release 0.5.1: init LogBuddy automatically unless SAFE_LOG_BUDDY is set

  • Loading branch information...
commit 887fa8e306ffc8c90237c89d65107eb6aca766bd 1 parent 4c27bb2
@rsanheim rsanheim authored
Showing with 9 additions and 2 deletions.
  1. +2 −0  CHANGELOG
  2. +6 −1 lib/log_buddy.rb
  3. +1 −1  lib/log_buddy/version.rb
View
2  CHANGELOG
@@ -1,3 +1,5 @@
+v0.5.1 init automatically unless SAFE_LOG_BUDDY (in ENV) is set
+
v0.5.0 Overall cleanup and making things safer:
- move to Rspec2
- move Version into the code base as a constant and out of yml
View
7 lib/log_buddy.rb
@@ -5,7 +5,10 @@
=begin rdoc
LogBuddy is a developer tool for easy logging while testing, debugging, and inspecting.
-The log shortcut method to give you easy, concise output of variables with their names and values.
+The <tt>d</tt> log method to give you easy, concise output of variables with their names and values.
+
+Requiring 'log_buddy' will _automatically_ mixin the <tt>d</tt> method into Object. You can avoid this
+behavior by setting SAFE_LOG_BUDDY to true in your environment before requiring LogBuddy.
Examples:
a = "foo"
@@ -65,4 +68,6 @@ def init_default_logger
end
end
+
+ init unless ENV["SAFE_LOG_BUDDY"]
end
View
2  lib/log_buddy/version.rb
@@ -2,7 +2,7 @@ module LogBuddy
module Version #:nodoc:
MAJOR = 0
MINOR = 5
- TINY = 0
+ TINY = 1
STRING = [MAJOR, MINOR, TINY].join('.')
end
Please sign in to comment.
Something went wrong with that request. Please try again.