File tree Expand file tree Collapse file tree 1 file changed +1
-4
lines changed Expand file tree Collapse file tree 1 file changed +1
-4
lines changed Original file line number Diff line number Diff line change 1717 runs-on : ubuntu-latest
1818 env :
1919 # The name of the Yamato check to monitor
20- CHECK_NAME : " Code changes PR checks"
20+ CHECK_NAME : " [Yamato] Code changes PR checks"
2121 # How long to wait for the check to appear before assuming it won't run
2222 GRACE_PERIOD_SECONDS : 120 # 2 minutes
2323 # How often to poll the GitHub API to see if job has finished (fail or succeeded)
4343 checks_json=$(gh pr checks ${{ github.event.pull_request.number }} --json name,state | jq ".[] | select(.name == \"$CHECK_NAME\")")
4444
4545 if [ -z "$check_status" ]; then
46- # Case 1: The check has not appeared yet.
4746 if [ $elapsed_seconds -gt $GRACE_PERIOD_SECONDS ]; then
4847 echo "Grace period of $GRACE_PERIOD_SECONDS seconds has passed and the check '$CHECK_NAME' was not found."
4948 echo "Assuming it was not triggered (e.g., docs-only change). Success!"
5251 echo "Check '$CHECK_NAME' not found yet. Continuing to poll..."
5352 fi
5453 elif [ "$check_status" == "pending" ]; then
55- # Case 2: The check is running.
5654 echo "Check '$CHECK_NAME' is currently '$check_status'. Waiting..."
5755 elif [ "$check_status" == "pass" ]; then
58- # Case 3: The check has finished.
5956 echo "Check '$CHECK_NAME' completed with conclusion: 'success'."
6057 exit 0
6158 else
You can’t perform that action at this time.
0 commit comments