From 53cbdbfc3f83910946d2fa91e8a60f9ad0c7ef3e Mon Sep 17 00:00:00 2001 From: lonkaars Date: Sun, 3 Apr 2022 19:48:22 +0200 Subject: added comments to configuration.an file spec --- autonyaa.py | 1 + readme.md | 2 ++ 2 files changed, 3 insertions(+) diff --git a/autonyaa.py b/autonyaa.py index b574114..a84e801 100755 --- a/autonyaa.py +++ b/autonyaa.py @@ -105,6 +105,7 @@ def parse_config_section(section): def parse_config_file(): parsed_sections = [] contents = config_file.read() + contents = re.sub(r'^#.*\n', '', contents, 0, re.M) sections = [x.strip() for x in contents.split("\n\n")] while "" in sections: sections.remove("") diff --git a/readme.md b/readme.md index ec18d27..e2ed22b 100644 --- a/readme.md +++ b/readme.md @@ -26,6 +26,8 @@ autonyaa should look up and match torrent titles. if you want to keep track of multiple anime's, you can define multiple config sections by seperating them with an empty line. here's a reference for all the configuration keys: +lines starting with a # are completely ignored + ### name ``` -- cgit v1.2.3