Refactor changed are done

This commit is contained in:
2023-06-23 12:17:01 +02:00
parent b003712358
commit 2a7870620c
9 changed files with 36 additions and 39 deletions

View File

@@ -11,9 +11,9 @@ def get_py_files(src):
cwd = getcwd() # Current Working directory
py_files = []
for root, dirs, files in walk(src):
for file in files:
if file.endswith(".py"):
py_files.append(Path(f"{cwd}/{root}/{file}"))
py_files.extend(
Path(f"{cwd}/{root}/{file}") for file in files if file.endswith(".py")
)
return py_files