diff options
author | Joel Challis <git@zvecr.com> | 2022-01-03 21:54:46 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-01-03 21:54:46 +0000 |
commit | aea71554234cce71f9f9d4087253e53d2729f9a7 (patch) | |
tree | aa4a529fc95f46670d76001163b4165d6108bec5 /lib/python/qmk/cli/format/python.py | |
parent | a88dc08643af76e19eff72dbd9b2a0cefea3f23f (diff) | |
download | qmk_firmware-aea71554234cce71f9f9d4087253e53d2729f9a7.tar.gz qmk_firmware-aea71554234cce71f9f9d4087253e53d2729f9a7.zip |
Fix "No C files in filelist: None" (#15560)
* Fix "No C files in filelist: None"
* Align other commands
* force absolute paths
Diffstat (limited to 'lib/python/qmk/cli/format/python.py')
-rwxr-xr-x | lib/python/qmk/cli/format/python.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/python/qmk/cli/format/python.py b/lib/python/qmk/cli/format/python.py index 47b5c45fd..008622cac 100755 --- a/lib/python/qmk/cli/format/python.py +++ b/lib/python/qmk/cli/format/python.py | |||
@@ -25,8 +25,9 @@ def yapf_run(files): | |||
25 | def filter_files(files): | 25 | def filter_files(files): |
26 | """Yield only files to be formatted and skip the rest | 26 | """Yield only files to be formatted and skip the rest |
27 | """ | 27 | """ |
28 | files = list(map(normpath, filter(None, files))) | ||
28 | for file in files: | 29 | for file in files: |
29 | if file and normpath(file).name.split('.')[-1] in py_file_suffixes: | 30 | if file.suffix[1:] in py_file_suffixes: |
30 | yield file | 31 | yield file |
31 | else: | 32 | else: |
32 | cli.log.debug('Skipping file %s', file) | 33 | cli.log.debug('Skipping file %s', file) |