Say a repeated heading appears more than once, a count the exit does not check

This commit is contained in:
2026-09-25 08:29:38 +02:00
parent 33621cc6ff
commit b52cecb895
3 changed files with 3 additions and 3 deletions
+1 -1
View File
@@ -106,7 +106,7 @@ def read_premises():
if not bodies:
sys.exit(f"README.md has no ## {name} heading - no premises.")
if len(bodies) > 1:
sys.exit(f"README.md has ## {name} twice - no premises.")
sys.exit(f"README.md has ## {name} more than once - no premises.")
if not bodies[0]:
sys.exit(f"README.md has nothing under ## {name} - no premises.")
return f"## Goals\n{found['Goals'][0]}\n\n## Audience\n{found['Audience'][0]}"