Skip to content
This repository was archived by the owner on Mar 14, 2023. It is now read-only.

Commit 6d7f6da

Browse files
committed
Remove vestigial cur_dir code.
1 parent 33b005f commit 6d7f6da

File tree

1 file changed

+0
-9
lines changed

1 file changed

+0
-9
lines changed

highfive/newpr.py

Lines changed: 0 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -358,22 +358,13 @@ def get_to_mention(self, diff, author):
358358
to_mention = set()
359359
# If there's directories with specially assigned groups/users
360360
# inspect the diff to find the directory with the most additions
361-
cur_dir = None
362361
for line in diff.split('\n'):
363362
if line.startswith("diff --git "):
364-
# update cur_dir
365-
cur_dir = None
366363
parts = line[line.find(" b/") + len(" b/"):].split("/")
367364
if not parts:
368365
continue
369-
cur_dir = "/".join(parts[:2])
370366
full_dir = "/".join(parts)
371367

372-
# A few heuristics to get better reviewers
373-
if cur_dir.startswith('src/librustc'):
374-
cur_dir = 'src/librustc'
375-
if cur_dir == 'src/test':
376-
cur_dir = None
377368
if len(full_dir) > 0:
378369
for entry in mentions:
379370
# Check if this entry is a prefix

0 commit comments

Comments
 (0)