Sha256: 73cef56c160d8ff6909569c8186fdeca72f7fe5980c489805436a354070aca24

Contents?: true

Size: 612 Bytes

Versions: 2

Compression:

Stored size: 612 Bytes

Contents

# frozen_string_literal: true

# require only the logger
require "formatador"
require "fog/core/logger"

module Backup
  class Logger
    module FogAdapter
      class << self
        # Logged as :info so these won't generate warnings.
        # This is mostly to keep STDOUT clean and to provide
        # supplemental messages for our own warnings.
        # These will generally occur during retry attempts.
        def write(message)
          Logger.info message.chomp
        end

        def tty?
          false
        end
      end
    end
  end
end

Fog::Logger[:warning] = Backup::Logger::FogAdapter

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
backupii-0.1.0.pre.alpha.2 lib/backup/logger/fog_adapter.rb
backupii-0.1.0.pre.alpha.1 lib/backup/logger/fog_adapter.rb