Skip to content

Commit 7ca16a2

Browse files
committed
bpo-38347: assume all files that end on '.py' are Python scripts
Assume all files that end on '.py' are Python scripts when working recursively.
1 parent d8e988e commit 7ca16a2

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

Tools/scripts/pathfix.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -89,11 +89,8 @@ def main():
8989
sys.exit(bad)
9090

9191

92-
ispythonprog = re.compile(r'^[a-zA-Z0-9_-]+\.py$')
93-
94-
9592
def ispython(name):
96-
return bool(ispythonprog.match(name))
93+
return name.endswith('.py')
9794

9895

9996
def recursedown(dirname):

0 commit comments

Comments
 (0)