summaryrefslogtreecommitdiffstats
path: root/Tools/scripts
diff options
context:
space:
mode:
authorRuediger Pluem <r.pluem@gmx.de>2019-10-11 13:36:50 (GMT)
committerVictor Stinner <vstinner@python.org>2019-10-11 13:36:50 (GMT)
commit2b7dc40b2af6578181808ba73c1533fc114e55df (patch)
tree4d570ccad09538a1da458e8eb8c84730966455a3 /Tools/scripts
parentcbb548130caf24275fa16100bccc537570cb46df (diff)
downloadcpython-2b7dc40b2af6578181808ba73c1533fc114e55df.zip
cpython-2b7dc40b2af6578181808ba73c1533fc114e55df.tar.gz
cpython-2b7dc40b2af6578181808ba73c1533fc114e55df.tar.bz2
bpo-38347: find pathfix for Python scripts whose name contain a '-' (GH-16536)
pathfix.py: Assume all files that end on '.py' are Python scripts when working recursively.
Diffstat (limited to 'Tools/scripts')
-rwxr-xr-xTools/scripts/pathfix.py5
1 files changed, 1 insertions, 4 deletions
diff --git a/Tools/scripts/pathfix.py b/Tools/scripts/pathfix.py
index 237a3d9..d252321 100755
--- a/Tools/scripts/pathfix.py
+++ b/Tools/scripts/pathfix.py
@@ -89,11 +89,8 @@ def main():
sys.exit(bad)
-ispythonprog = re.compile(r'^[a-zA-Z0-9_]+\.py$')
-
-
def ispython(name):
- return bool(ispythonprog.match(name))
+ return name.endswith('.py')
def recursedown(dirname):