Module: Rabal::Log

Included in:
Application
Defined in:
lib/rabal/logger.rb

Class Method Summary collapse

Class Method Details

.loggerObject



6
7
8
9
10
11
# File 'lib/rabal/logger.rb', line 6

def logger
    return @logger if @logger
    @logger = ::Logger.new($stdout)
    @logger.datetime_format ="%Y-%m-%d %H:%M:%S"
    @logger
end

.logger=(log) ⇒ Object



13
14
15
16
17
# File 'lib/rabal/logger.rb', line 13

def logger=(log)
    @logger = ::Logger.new(log)
    @logger.datetime_format ="%Y-%m-%d %H:%M:%S"
    @logger
end