Sha256: 01ff0bb38e174d6baa538905680630b4c1d34c378e60f158abc06335c0396657

Contents?: true

Size: 254 Bytes

Versions: 3

Compression:

Stored size: 254 Bytes

Contents

module HubLink
  class SimpleLogger < SimpleDelegator
    def initialize(output = "hub_link.log")
      logger = Logger.new(output)
      logger.formatter = ->(_, datetime, _, msg) { "#{datetime} - #{msg}\n" }
      __setobj__(logger)
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
hub_link-0.19.0 lib/hub_link/simple_logger.rb
hub_link-0.18.0 lib/hub_link/simple_logger.rb
hub_link-0.15.0 lib/hub_link/simple_logger.rb