diff options
Diffstat (limited to 'scripts/code_tools')
-rw-r--r-- | scripts/code_tools/fix_whitespace.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/code_tools/fix_whitespace.py b/scripts/code_tools/fix_whitespace.py index 37e15c6d10..91e82f26f4 100644 --- a/scripts/code_tools/fix_whitespace.py +++ b/scripts/code_tools/fix_whitespace.py @@ -33,6 +33,10 @@ def convert_tabs_to_spaces(file_path, tab_stop): with open(file_path, 'r') as file: lines = file.readlines() + # Skip files with no tabs + if not any('\t' in line for line in lines): + return + new_lines = [] for line in lines: # Remove trailing spaces |