Simplify glob

Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
This commit is contained in:
Hugo van Kemenade 2023-04-09 22:43:36 +03:00 committed by GitHub
parent 6797e47458
commit 80a1238e2b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,6 +1,6 @@
import sys
from pathlib import Path
for rst in Path("docs/releasenotes/").rglob("[1-9]*.rst"):
for rst in Path("docs/releasenotes").glob("[1-9]*.rst"):
if "TODO" in open(rst).read():
sys.exit(f"Error: remove TODO from {rst}")