summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndre Arko <andre@arko.net>2010-11-12 23:15:14 -0600
committerAndre Arko <andre@arko.net>2010-11-13 01:14:43 -0600
commit25c6f9305275fc8276fa7dda83ed73726367593a (patch)
tree02a65f4e80ba6c3840d3514b6db2f2eece90a713
parentdcccd31b27c8ea3488a9046495511cf3b4e067cd (diff)
downloadbundler-25c6f9305275fc8276fa7dda83ed73726367593a.tar.gz
Add Bundler::UI#debug! (already on if ENV["DEBUG"] is set)
-rw-r--r--lib/bundler/ui.rb7
1 files changed, 6 insertions, 1 deletions
diff --git a/lib/bundler/ui.rb b/lib/bundler/ui.rb
index aa06101216..4949a7c53c 100644
--- a/lib/bundler/ui.rb
+++ b/lib/bundler/ui.rb
@@ -19,10 +19,11 @@ module Bundler
def initialize(shell)
@shell = shell
@quiet = false
+ @debug = ENV['DEBUG']
end
def debug(msg)
- @shell.say(msg) if ENV['DEBUG'] && !@quiet
+ @shell.say(msg) if @debug && !@quiet
end
def info(msg)
@@ -44,6 +45,10 @@ module Bundler
def be_quiet!
@quiet = true
end
+
+ def debug!
+ @debug = true
+ end
end
class RGProxy < Gem::SilentUI