Sha256: a178069416c34a1ef2d35f41350275b96bb4599743b466e048d8cb29e047ba00

Contents?: true

Size: 476 Bytes

Versions: 20

Compression:

Stored size: 476 Bytes

Contents

require 'logger'

unless ENV['LAMBY_TEST']

  ENV['RAILS_LOG_TO_STDOUT'] = '1'

  module Lamby
    module Logger

      def initialize(*args)
        args[0] = STDOUT
        super(*args)
      end

    end
  end

  Logger.prepend Lamby::Logger

end

# TODO: Railtie initializer
# Rails.application.config.logger = ActiveSupport::TaggedLogging.new(
#   ActiveSupport::Logger.new(STDOUT).tap { |logger|
#     logger.formatter = Rails.application.config.log_formatter
#   }
# )

Version data entries

20 entries across 20 versions & 1 rubygems

Version Path
lamby-3.0.2 lib/lamby/logger.rb
lamby-3.0.1 lib/lamby/logger.rb
lamby-3.0.0 lib/lamby/logger.rb
lamby-2.8.0 lib/lamby/logger.rb
lamby-2.7.1 lib/lamby/logger.rb
lamby-2.7.0 lib/lamby/logger.rb
lamby-2.6.3 lib/lamby/logger.rb
lamby-2.6.2 lib/lamby/logger.rb
lamby-2.6.1 lib/lamby/logger.rb
lamby-2.6.0 lib/lamby/logger.rb
lamby-2.5.3 lib/lamby/logger.rb
lamby-2.5.2 lib/lamby/logger.rb
lamby-2.5.1 lib/lamby/logger.rb
lamby-2.5.0 lib/lamby/logger.rb
lamby-2.2.2 lib/lamby/logger.rb
lamby-2.2.1 lib/lamby/logger.rb
lamby-2.2.0 lib/lamby/logger.rb
lamby-2.1.0 lib/lamby/logger.rb
lamby-2.0.1 lib/lamby/logger.rb
lamby-2.0.0 lib/lamby/logger.rb