RFR: 1949: Handle maintainer approval from pull request [v5]

Zhao Song zsong at openjdk.org
Thu Aug 17 20:08:00 UTC 2023

> As Erik said in the issue, "In SKARA-1199, we added the optional ability for a PR to block integration until a certain approval label appears on all the associated bugs. To further improve the workflow, we would like to add a couple of PR commands that will make it possible to perform the whole maintainer approval workflow through the PR"
> Therefore, in this patch, two pull request commands(`/approval` and `/approve`) are introduced.
> 1. Command `/approval`
> Usage: `/approval [<id>] (request|cancel) [<text>]`
> Examples: `/approval request my reason`, `/approval cancel`, 
>                  `/approval JDK-123 request my reason`, `/approval 123 cancel`
> Only the author of the pull request is allowed to issue this command. If the user requested approval, the text will be posted to the bug. The user will be able to update the text by requesting the approval again. Once maintainer processed the request(approved or rejected), the user will not be able to request or cancel the approval.
> If there is only one issue associated with the pr, the user will not need to specify the issue id. If there are more than one issues associated with the pr, the user should specify the issue id in the command.
> 2. Command `/approve`
> Usage: `/approve [<id>] (yes|no)`
> Examples: `/approve yes`, `/approve no`, `/approve JDK-123 yes`, `/approve 123 no`
> Only maintainers of the repo are allowed to issue this command. Maintainers can not approve or reject the approval if the request doesn't exist.
> If the user doesn't specify the issue id in the command, then all the approval request in issues associated with pull request will be handled.

Zhao Song has updated the pull request incrementally with two additional commits since the last revision:

 - update
 - Update bots/pr/src/main/java/org/openjdk/skara/bots/pr/ApproveCommand.java
   Co-authored-by: Erik Joelsson <37597443+erikj79 at users.noreply.github.com>


  - all: https://git.openjdk.org/skara/pull/1544/files
  - new: https://git.openjdk.org/skara/pull/1544/files/5105d7dd..453418a3

 - full: https://webrevs.openjdk.org/?repo=skara&pr=1544&range=04
 - incr: https://webrevs.openjdk.org/?repo=skara&pr=1544&range=03-04

  Stats: 4 lines in 2 files changed: 0 ins; 0 del; 4 mod
  Patch: https://git.openjdk.org/skara/pull/1544.diff
  Fetch: git fetch https://git.openjdk.org/skara.git pull/1544/head:pull/1544

PR: https://git.openjdk.org/skara/pull/1544

More information about the skara-dev mailing list