docs: def write_config(filename, config, mode="w"):
      '''use configparser to write a config object to filename
      '''
      with open(filename, mode) as filey:
          config.write(filey)
      return filename