Add tea pulls --state mergeable filter #260

Open
opened 2020-12-02 12:46:42 +00:00 by khmarbaise · 1 comment
Member

It would be really nice to have information about reviews which have been approved.

For example something like this:

tea pr reviews --approved

which could show a list or simply a number with the option (makes it easier for automation tools) which would make it easier to automate things.

tea pr reviews

to list all existing reviews

If I understood correctly currently Gitea (1.13.0) does not yet provide information about reviews (yes) but not reviews approved in REST API?

related to #258

It would be really nice to have information about reviews which have been approved. For example something like this: ``` tea pr reviews --approved ``` which could show a list or simply a number with the option (makes it easier for automation tools) which would make it easier to automate things. ``` tea pr reviews ``` to list all existing reviews If I understood correctly currently Gitea (1.13.0) does not yet provide information about reviews (yes) but not reviews approved in REST API? related to #258
lunny added the
kind/proposal
label 2020-12-02 12:57:49 +00:00
Member

If it's about checking what PRs are mergable for automation, I suggest

tea pulls --state mergeable

Which would only list PRs that are

  • open
  • have .Mergable tue (i.e. no merge conflicts)
  • have enough approvals

The latter would need two additional fetches (client.GetBranchProtections(), client.ListPullReviews())

This condition seems so common though, that it might make sense for the gitea to return this flag in the API.. see https://github.com/go-gitea/gitea/issues/13879

If it's about checking what PRs are mergable for automation, I suggest ``` tea pulls --state mergeable ``` Which would only list PRs that are - open - have .Mergable tue (i.e. no merge conflicts) - have enough approvals The latter would need two additional fetches (`client.GetBranchProtections()`, `client.ListPullReviews()`) This condition seems so common though, that it might make sense for the gitea to return this flag in the API.. see https://github.com/go-gitea/gitea/issues/13879
noerw added the
upstream/gitea
label 2021-03-06 23:22:42 +00:00
noerw changed title from Information about reviews which are approved for pull request on command line to Add `tea pulls --state mergeable` filter 2021-09-28 11:12:21 +00:00
Sign in to join this conversation.
No Milestone
No Assignees
2 Participants
Notifications
Due Date
The due date is invalid or out of range. Please use the format 'yyyy-mm-dd'.

No due date set.

Dependencies

No dependencies set.

Reference: gitea/tea#260
No description provided.