gerrit's mail when adding a reviewer
d.ostrovsky at idaia.de
d.ostrovsky at idaia.de
Thu Mar 28 06:23:08 PDT 2013
Quoting Stephan Bergmann <sbergman at redhat.com>:
> On 03/28/2013 10:22 AM, Bjoern Michaelsen wrote:
>> On Wed, Mar 27, 2013 at 01:28:18PM +0100, Stephan Bergmann wrote:
>>> Just noticed that when I add a reviewer to somebody else's change,
>>> gerrit sends a mail taking on my identity ("Stephan Bergmann (via
>>> Code Review) <gerrit at gerrit.libreoffice.org>") claiming "I have
>>> submitted a patch for review." But I did not submit anything for
>>> review, I merely invited somebody else to also review something. I
>>> find that confusing at least.
>>
>> If you find a better wording, submit a patch for:
>>
>>
>> https://gerrit.libreoffice.org/gitweb?p=gerrit-etc.git;a=blob;f=mail/NewChange.vm;h=34af52f6a6c9a90fe9e9bb758d9c9721eea9bba0;hb=a60a0f9771a6d31c3e6c0c1b3745613264678b3f
>
> But is that text only used when one adds an additional reviewer to
> an existing change, or is it also used for the initial mail when a
> new change is uploaded?
let code speak:
https://gerrit.googlesource.com/gerrit/+/master/gerrit-server/src/main/java/com/google/gerrit/server/change/PostReviewers.java
in the method
private void postAdd(Change change, PostResult result)
mail is unconditionally sent using AddReviewerSender factory:
if (!added.isEmpty()) {
AddReviewerSender cm;
[...]
cm.send();
}
looking at it:
public class AddReviewerSender extends NewChangeSender
you can figure out, that it inherits from NewChangeSender:
https://gerrit.googlesource.com/gerrit/+/master/gerrit-server/src/main/java/com/google/gerrit/server/mail/NewChangeSender.java
using that template:
@Override
protected void formatChange() throws EmailException {
appendText(velocifyFile("NewChange.vm"));
}
and looking at RTFM it is even documented:
http://gerrit-documentation.googlecode.com/svn/Documentation/2.6/config-mail.html#_newchange_vm
If that is not what you expect, file a gerrit bug here:
https://code.google.com/p/gerrit/issues/list
David
More information about the LibreOffice
mailing list