Class: Floe::CLI::Logger
- Inherits:
-
Logger
- Object
- Logger
- Floe::CLI::Logger
- Defined in:
- lib/floe/cli/logger.rb
Instance Attribute Summary collapse
-
#execution_id ⇒ Object
Returns the value of attribute execution_id.
Instance Method Summary collapse
-
#initialize ⇒ Logger
constructor
A new instance of Logger.
Constructor Details
#initialize ⇒ Logger
Returns a new instance of Logger.
10 11 12 13 14 15 16 17 18 |
# File 'lib/floe/cli/logger.rb', line 10 def initialize(...) super original_formatter = formatter || ::Logger::Formatter.new self.formatter = proc do |severity, time, progname, msg| prefix = execution_id ? "[#{execution_id}] " : "" original_formatter.call(severity, time, progname, "#{prefix}#{msg}") end end |
Instance Attribute Details
#execution_id ⇒ Object
Returns the value of attribute execution_id.
8 9 10 |
# File 'lib/floe/cli/logger.rb', line 8 def execution_id @execution_id end |