code: def banner_print(msg, color='', width=60, file=sys.stdout, logger=_LOG):
    
    if logger:
      logger.debug(ANSI_ESC_RE.sub('', msg))
    if CLI_QUIET:
      return
    lpad = int(math.ceil((width - _printed_len(msg) - 2) / 2.0)) * '='
    rpad = int(math.floor((width - _printed_len(msg) - 2) / 2.0)) * '='
    file.write('{sep}{color}{lpad} {msg} {rpad}{reset}{sep}{sep}'.format(
        sep=_linesep_for_file(file), color=color, lpad=lpad, msg=msg, rpad=rpad,
        reset=colorama.Style.RESET_ALL))
    file.flush()
docs: Print the message as a banner with a fixed width.
  
    Also logs the message (un-bannered) to the given logger at the debug level.
  
    Args:
      msg: The message to print.
      color: Optional colorama color string to be applied to the message. You can
          concatenate colorama color strings together in order to get any set of
          effects you want.
      width: Total width for the resulting banner.
      file: A file object to which the banner text will be written. Intended for
          use with CLI output file objects like sys.stdout.
      logger: A logger to use, or None to disable logging.
  
    Example:
  
      >>> banner_print('Foo Bar Baz')
  
      ======================== Foo Bar Baz =======================