voicemeeter-rb/lib/voicemeeter/logger.rb

12 lines
252 B
Ruby
Raw Normal View History

require "logger"
module Voicemeeter
module Logging
def logger
@logger = Logger.new($stdout, level: ENV.fetch("VM_LOG_LEVEL", "WARN"))
2023-07-25 12:58:32 +01:00
@logger.progname = instance_of?(::Module) ? name : self.class.name
@logger
end
end
end