Skip to content

Commit 9d3d995

Browse files
committed
lint-history: avoid dying when we get file deletions
When a file is deleted, there is nothing to lint, so we can just keep the deletion as-is. Reported-by: Thorben Kröger <[email protected]> Signed-off-by: Elijah Newren <[email protected]>
1 parent 4ea19c0 commit 9d3d995

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

contrib/filter-repo-demos/lint-history

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,8 @@ def lint_with_real_filenames(commit, metadata):
5959
for change in commit.file_changes:
6060
if change.blob_id in blobs_handled:
6161
change.blob_id = blobs_handled[change.blob_id]
62+
elif change.type == b'D':
63+
continue
6264
else:
6365
# Get the old blob contents
6466
cat_file_process.stdin.write(change.blob_id + b'\n')

0 commit comments

Comments
 (0)