From: XhmikosR Date: Sun, 5 Jul 2026 14:53:50 +0000 (+0300) Subject: Close the README template file after reading it X-Git-Url: http://git.99rst.org/?a=commitdiff_plain;h=15aa742a195d0a909600d6d52b1bec4c09b6940f;p=stevenblack-hosts.git Close the README template file after reading it --- diff --git a/updateReadme.py b/updateReadme.py index 779257f91..0421a4a67 100755 --- a/updateReadme.py +++ b/updateReadme.py @@ -90,8 +90,10 @@ def main(): "wt", encoding="utf-8", newline="\n", - ) as out: - for line in open(README_TEMPLATE, encoding="utf-8", newline="\n"): + ) as out, open( + README_TEMPLATE, encoding="utf-8", newline="\n" + ) as template: + for line in template: line = line.replace( "@GEN_DATE@", time.strftime("%B %d %Y", time.gmtime()) )