diff options
author | teor <teor@torproject.org> | 2020-04-03 19:11:08 +1000 |
---|---|---|
committer | teor <teor@torproject.org> | 2020-04-03 19:16:57 +1000 |
commit | a762234ba27d89f3394e560c2b0cf976648ca779 (patch) | |
tree | 772738343ded1192cf2c162d56268b1a147410c7 /scripts/maint/rename_c_identifier.py | |
parent | 442e0caea2910b43616560e8d95cd4138c377257 (diff) | |
download | tor-a762234ba27d89f3394e560c2b0cf976648ca779.tar.gz tor-a762234ba27d89f3394e560c2b0cf976648ca779.zip |
scripts: Ignore editor temporary files
Ignore editor temporary files when autostyling in:
* rectify_include_paths.py
* rename_c_identifier.py
Obviously correct changes to already-reviewed code.
Diffstat (limited to 'scripts/maint/rename_c_identifier.py')
-rwxr-xr-x | scripts/maint/rename_c_identifier.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/maint/rename_c_identifier.py b/scripts/maint/rename_c_identifier.py index 6e0c1d8cf1..77802e10f3 100755 --- a/scripts/maint/rename_c_identifier.py +++ b/scripts/maint/rename_c_identifier.py @@ -44,7 +44,8 @@ def is_c_file(fn): False """ fn = os.path.split(fn)[1] - if fn.startswith("."): + # Avoid editor temporary files + if fn.startswith(".") or fn.startswith("#"): return False ext = os.path.splitext(fn)[1] return ext in {".c", ".h", ".i", ".inc"} |