Sha256: 7d2b9a537f5c802f702acc08e196b61b4308a8d722962f26a9433e52e404e419
Contents?: true
Size: 446 Bytes
Versions: 9
Compression:
Stored size: 446 Bytes
Contents
require 'logger' require 'fileutils' module Puggernaut module Logger def logger Puggernaut::Logger.logger end class <<self def logger unless @logger base = Dir.pwd FileUtils.mkdir_p("#{base}/log") file = File.open("#{base}/log/puggernaut.log", 'a') file.sync = true @logger = ::Logger.new(file) end @logger end end end end
Version data entries
9 entries across 9 versions & 1 rubygems