Sha256: 93b4aed32edccc4794d45ac429dd920ba34cf8ccac593a8cbc82a3433da2f783

Contents?: true

Size: 386 Bytes

Versions: 7

Compression:

Stored size: 386 Bytes

Contents

require 'rubygems'
require 'tagged_logger'
require 'logger'

puts "\n<<<#{File.basename(__FILE__, ".rb")}>>> \n".upcase

module Active
  class Base
    def foo
      logger.info("foo")
    end
  end
end

TaggedLogger.rules do
  puts "- The recommended way to specify logging for all classes within same namespace:"
  info /Active::/, :to => Logger.new(STDOUT)
end

Active::Base.new.foo

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
tagged_logger-0.4.5 examples/rule_with_regex.rb
tagged_logger-0.4.2 examples/rule_with_regex.rb
tagged_logger-0.4.0 examples/rule_with_regex.rb
tagged_logger-0.3.3 examples/rule_with_regex.rb
tagged_logger-0.3.2 examples/rule_with_regex.rb
tagged_logger-0.3.1 examples/rule_with_regex.rb
tagged_logger-0.3.0 examples/rule_with_regex.rb