mirror of
https://chromium.googlesource.com/chromium/tools/depot_tools.git
synced 2026-01-11 18:51:29 +00:00
Print clarifying message when no new owners needed
If a CL already has owners on the reviewer list that cover all of the files - regardless of whether they have approved the change - git cl owners just prints ** You selected these owners **, which can be confusing. This change adds an explanation in the no-unowned-files case and suggests using --ignore-current if more reviewers are wanted. Bug: 1071967 Change-Id: If60455c5ec15006e09feed39633fa62e3ddf0a04 Reviewed-on: https://chromium-review.googlesource.com/c/chromium/tools/depot_tools/+/2183222 Reviewed-by: Edward Lesmes <ehmaldonado@chromium.org> Commit-Queue: Bruce Dawson <brucedawson@chromium.org>
This commit is contained in:
@@ -334,14 +334,19 @@ class OwnersFinder(object):
|
||||
# Print results
|
||||
self.writeln()
|
||||
self.writeln()
|
||||
self.writeln('** You selected these owners **')
|
||||
self.writeln()
|
||||
for owner in self.selected_owners:
|
||||
self.writeln(self.bold_name(owner) + ':')
|
||||
self.indent()
|
||||
for file_name in sorted(self.owners_to_files[owner]):
|
||||
self.writeln(file_name)
|
||||
self.unindent()
|
||||
if len(self.selected_owners) == 0:
|
||||
self.writeln('This change list already has owner-reviewers for all '
|
||||
'files.')
|
||||
self.writeln('Use --ignore-current if you want to ignore them.')
|
||||
else:
|
||||
self.writeln('** You selected these owners **')
|
||||
self.writeln()
|
||||
for owner in self.selected_owners:
|
||||
self.writeln(self.bold_name(owner) + ':')
|
||||
self.indent()
|
||||
for file_name in sorted(self.owners_to_files[owner]):
|
||||
self.writeln(file_name)
|
||||
self.unindent()
|
||||
|
||||
def bold(self, text):
|
||||
return self.COLOR_BOLD + text + self.COLOR_RESET
|
||||
|
||||
Reference in New Issue
Block a user