diff --git a/lib/guard.rb b/lib/guard.rb index 8a8abc2..5cad6bd 100644 --- a/lib/guard.rb +++ b/lib/guard.rb @@ -43,7 +43,10 @@ module Guard def run_on_change_for_all_guards(files) guards.each do |guard| paths = Watcher.match_files(guard, files) - supervised_task(guard, :run_on_change, paths) unless paths.empty? + unless paths.empty? + UI.debug "#{guard.class.name}#run_on_change with #{paths.inspect}" + supervised_task(guard, :run_on_change, paths) + end end # Reparse the whole directory to catch new files modified during the guards run diff --git a/lib/guard/ui.rb b/lib/guard/ui.rb index 71ee8e7..1751615 100644 --- a/lib/guard/ui.rb +++ b/lib/guard/ui.rb @@ -26,7 +26,7 @@ module Guard def debug(message, options = {}) unless ENV["GUARD_ENV"] == "test" reset_line if options[:reset] - puts "DEBUG: #{message}" if ::Guard.options && ::Guard.options[:debug] + puts "DEBUG (#{Time.now.strftime('%T')}): #{message}" if ::Guard.options && ::Guard.options[:debug] end end