code: def set_up(verbose, quiet):
      
      logger = logging.getLogger('fades')
      logger.setLevel(logging.DEBUG)
  
      # select logging level according to user desire; also use a simpler
      # formatting for non-verbose logging
      if verbose:
          log_level = logging.DEBUG
          log_format = FMT_DETAILED
      elif quiet:
          log_level = logging.WARNING
          log_format = FMT_SIMPLE
      else:
          log_level = logging.INFO
          log_format = FMT_SIMPLE
  
      # all to the stdout
      handler = SalutingStreamHandler(logger)
      handler.setLevel(log_level)
      logger.addHandler(handler)
      formatter = logging.Formatter(log_format)
      handler.setFormatter(formatter)
  
      # and to the syslog
      for syslog_path in ('/dev/log', '/var/run/syslog'):
          if not os.path.exists(syslog_path):
              continue
          try:
              handler = logging.handlers.SysLogHandler(address=syslog_path)
          except Exception:
              # silently ignore that the user doesn't have a syslog active; can
              # see all the info with "-v" anyway
              pass
          else:
              logger.addHandler(handler)
              formatter = logging.Formatter(FMT_SYSLOG)
              handler.setFormatter(formatter)
              break
  
      return logger
docs: Set up the logging.