Commit 1411a95b authored by Vincent Michel's avatar Vincent Michel

Do not use configparser (non-standard ini files)

parent 5cdd3daf
......@@ -416,11 +416,5 @@ def get_config_files(path):
def get_config(filename):
"""Read and return the given config file as a dictionary."""
# Make sure the file exists
open(filename).close()
# Customize parser
config = configparser.ConfigParser(
comment_prefixes=['START', 'END', '#', '*****'])
# Read and parse
config.read([filename])
return {section: dict(config[section]) for section in config.sections()}
with open(filename) as f:
return f.read()
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment