RFR: 1997: Allow the creator of a PR to set the commit author [v2]

Zhao Song zsong at openjdk.org
Fri Sep 1 16:21:34 UTC 2023


On Fri, 1 Sep 2023 13:56:21 GMT, Erik Joelsson <erikj at openjdk.org> wrote:

>> Zhao Song has updated the pull request incrementally with three additional commits since the last revision:
>> 
>>  - Update bots/pr/src/main/java/org/openjdk/skara/bots/pr/AuthorCommand.java
>>    
>>    Co-authored-by: Erik Joelsson <37597443+erikj79 at users.noreply.github.com>
>>  - Update bots/pr/src/main/java/org/openjdk/skara/bots/pr/AuthorCommand.java
>>    
>>    Co-authored-by: Erik Joelsson <37597443+erikj79 at users.noreply.github.com>
>>  - Update bots/pr/src/main/java/org/openjdk/skara/bots/pr/AuthorCommand.java
>>    
>>    Co-authored-by: Erik Joelsson <37597443+erikj79 at users.noreply.github.com>
>
> bots/pr/src/main/java/org/openjdk/skara/bots/pr/AuthorCommand.java line 91:
> 
>> 89:                 }
>> 90:                 reply.println(Authors.setAuthorMarker(author.get()));
>> 91:                 reply.println("Author of this pull request has been set to `" + author.get() + "` successfully.");
> 
> I think we need to change the language a bit. Claiming that the author of the pull request has changed can be confusing, because the author isn't actually changing in the forge. I think "pull request author" and "overriding author" are better terms. 
> Suggestion:
> 
>                 reply.println("Setting overriding author to `" + author.get() + "`. When this pull request is integrated, the overriding author will be used in the commit.");

Looks good. Thanks for the suggestion!

> bots/pr/src/main/java/org/openjdk/skara/bots/pr/Authors.java line 32:
> 
>> 30: import java.util.regex.*;
>> 31: 
>> 32: class Authors {
> 
> I think this class should be just `Author` since we can never set more than one , or perhaps `OverridingAuthor` to make it even clearer what it is.

I prefer the name OverridingAuthor because we already have a Class called Author in package vcs.

-------------

PR Review Comment: https://git.openjdk.org/skara/pull/1553#discussion_r1313242619
PR Review Comment: https://git.openjdk.org/skara/pull/1553#discussion_r1313241162


More information about the skara-dev mailing list