Class: GitReflow::Logger

Inherits:
Logger
  • Object
show all
Defined in:
lib/git_reflow/logger.rb

Defined Under Namespace

Classes: SimpleFormatter

Constant Summary collapse

DEFAULT_LOG_FILE =
"/tmp/git-reflow.log"
COLORS =
{
  "FATAL" => :red,
  "ERROR" => :red,
  "WARN"  => :orange,
  "INFO"  => :yellow,
  "DEBUG" => :white,
}

Instance Method Summary collapse

Constructor Details

#initialize(*args) ⇒ Logger

Returns a new instance of Logger.



15
16
17
18
19
20
# File 'lib/git_reflow/logger.rb', line 15

def initialize(*args)
  log_file = args.shift || log_file_path
  args.unshift(log_file)
  super(*args)
  @formatter = SimpleFormatter.new
end