Skip to content

Example

Example #13

Workflow file for this run

name: Example
on:
workflow_run:
workflows:
- Review-Trigger
types:
- completed
jobs:
review-approvals:
runs-on: ubuntu-latest
steps:
- name: Publish payload
run: echo "$PAYLOAD"
env:
PAYLOAD: ${{toJson(github.event.workflow_run)}}
- name: Publish PR NUMBER
run: echo "$NUMBER"
env:
NUMBER: ${{ github.event.workflow_run.pull_requests[0].number }}
- name: Extract content of artifact
id: number
uses: Bullrich/[email protected]
with:
artifact-name: pr_number
- name: Generate token
id: app_token
uses: actions/[email protected]
with:
app-id: ${{ secrets.REVIEW_APP_ID }}
private-key: ${{ secrets.REVIEW_APP_KEY }}
- name: "Evaluates PR reviews and assigns reviewers"
uses: paritytech/[email protected]
with:
repo-token: ${{ steps.app_token.outputs.token }}
team-token: ${{ steps.app_token.outputs.token }}
checks-token: ${{ steps.app_token.outputs.token }}
pr-number: ${{ steps.number.outputs.content }}
request-reviewers: true