Allow Admin Bot to submit on behalf of others.
diff --git a/rules.pl b/rules.pl
index b2e5e5e..93730cb 100644
--- a/rules.pl
+++ b/rules.pl
@@ -4,11 +4,18 @@
non_author_code_review(L2, L3),
Out =.. [submit | L3].
+%% CLs authored by non-Google developers can be submitted by others.
only_author_can_submit(S, S) :-
gerrit:commit_author(_, _, Email),
\+ regex_matches('@google.com', Email),
!.
+%% The Admin Bot (ID:6165) can submit on behalf of others.
+only_author_can_submit(S, S) :-
+ gerrit:current_user(Id),
+ Id == '6165',
+ !.
+
only_author_can_submit(S, S) :-
gerrit:commit_author(Id),
gerrit:current_user(Id),