Open carolynvs opened 2 years ago
Shoot, this won't work for PRs from a fork because pull_request_review is locked to read access. I had hoped that the event worked the same as pull_request_target, using the workflow definition from the base ref, but unfortunately it uses the ref from the pull request (which would be unsafe to grant write access to).
So this is a non-starter until github supports an event like pull_request_review_target.
Re-opening because I think that we can trigger an empty workflow name "review-submitted" when a PR review is completed. It does nothing though. Instead another workflow is triggered when the review-submitted workflow completes with the workflow_run event. In this workflow we will have a token with write access and can then react to slash commands.
It would be great if when doing a GitHub code review, if the reviewer used /lgtm or /approve in the summarizing review comment, that it was recognized by the github action. I think without that, it would be easy for people to do a review with those commands, and not realize that their command isn't being acted upon.
I'm going to look into what events we'd need to listen for to make this work.