diff options
author | Carlos Garnacho <carlosg@gnome.org> | 2021-07-13 14:26:59 +0200 |
---|---|---|
committer | Carlos Garnacho <carlosg@gnome.org> | 2021-07-13 14:26:59 +0200 |
commit | f153497c708a5392bd274a7f14172856e78e467e (patch) | |
tree | d8eeeabb3980e8980a2dfda40f890a85f1fbca31 /check-style.py | |
parent | cdb7d836f3d21e8da2769a6bc3b531968ced3192 (diff) | |
download | tracker-f153497c708a5392bd274a7f14172856e78e467e.tar.gz |
check-style: Ignore chunks that only contain deleted code
These have no code style to check.
Diffstat (limited to 'check-style.py')
-rwxr-xr-x | check-style.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/check-style.py b/check-style.py index 4b59f83ae..eebd13659 100755 --- a/check-style.py +++ b/check-style.py @@ -29,7 +29,7 @@ def find_chunks(diff): len = int(match.group(2)) end = start + len - if file.endswith('.c') or file.endswith('.h') or file.endswith('.vala'): + if len > 0 and (file.endswith('.c') or file.endswith('.h') or file.endswith('.vala')): chunks.append({ 'file': file, 'start': start, 'end': end }) return chunks |