-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
70fdb5d
commit 5d6cf14
Showing
1 changed file
with
31 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
name: "Rerun FE Conditional Review Workflow" | ||
|
||
on: | ||
pull_request_review: | ||
types: [submitted, edited, dismissed] | ||
|
||
env: | ||
GITHUB_TOKEN: ${{ secrets.REPO_TOKEN }} | ||
|
||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
rerun-fe-conditional-review-workflow: | ||
runs-on: ubuntu-latest | ||
permissions: write-all | ||
steps: | ||
- name: Checkout code | ||
uses: actions/checkout@v3 | ||
|
||
- name: Get latest workflow run ID | ||
id: get_run_id | ||
run: | | ||
LATEST_RUN_ID=$(gh run list --repo ${{ github.repository }} --branch ${{ github.event.pull_request.head.ref }} --json databaseId,name --jq '.[] | select(.name == "FE Conditional Review") | .databaseId' | head -n 1) | ||
echo "LATEST_RUN_ID=$LATEST_RUN_ID" >> $GITHUB_ENV | ||
- name: Rerun latest workflow | ||
if: env.LATEST_RUN_ID != '' | ||
run: gh run rerun ${{ env.LATEST_RUN_ID }} --repo ${{ github.repository }} |