Add an `--ignore-current` flag to `git cl owners` to start from scratch.
Change-Id: Iee6d7cf87281d4ca0abf71a7109f678d5cbbc9f1
Reviewed-on: https://chromium-review.googlesource.com/1091801
Reviewed-by: Aaron Gable <agable@chromium.org>
Commit-Queue: Sidney San Martín <sdy@chromium.org>
diff --git a/git_cl.py b/git_cl.py
index 807fbc9..143ff3b 100755
--- a/git_cl.py
+++ b/git_cl.py
@@ -5679,6 +5679,10 @@
def CMDowners(parser, args):
"""Finds potential owners for reviewing."""
parser.add_option(
+ '--ignore-current',
+ action='store_true',
+ help='Ignore the CL\'s current reviewers and start from scratch.')
+ parser.add_option(
'--no-color',
action='store_true',
help='Use this option to disable color output')
@@ -5714,7 +5718,7 @@
affected_files,
change.RepositoryRoot(),
author,
- cl.GetReviewers(),
+ [] if options.ignore_current else cl.GetReviewers(),
fopen=file, os_path=os.path,
disable_color=options.no_color,
override_files=change.OriginalOwnersFiles()).run()