chore(ci): depug #5
Workflow file for this run
This file contains hidden or 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
| name: Garnix Test | |
| on: | |
| push: | |
| jobs: | |
| garnix: | |
| name: Wait on Garnix CI | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Wait on Garnix CI Check Suite | |
| env: | |
| GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| REPO: ${{ github.repository }} | |
| REF: ${{ github.head_ref || github.sha }} | |
| run: | | |
| sleep 16 | |
| check_suites=$(gh api \ | |
| -H "Accept: application/vnd.github+json" \ | |
| -H "X-GitHub-Api-Version: 2022-11-28" \ | |
| "/repos/$REPO/commits/$REF/check-suites") | |
| url=$(echo $check_suites | jq -r '.check_suites | .[] | select(.app.name == "Garnix CI") | .check_runs_url') | |
| status='' | |
| while [[ $status != 'completed' ]]; do | |
| sleep 16 | |
| app2_run=$(curl "$url" | jq '.check_runs | .[] | select(.name == "package app2 [x86_64-linux]")') | |
| echo "RAW" | |
| echo $app2_run | |
| status=$(echo $app2_run | jq '.status') | |
| echo "STATUS" | |
| echo $status | |
| done | |
| conclusion=$(echo $app2_run | jq '.conclusion') | |
| case "$conclusion" in | |
| failure | timed_out | action_required | stale | startup_failure) | |
| echo "ERROR: Garnix CI concluded with $conclusion" | |
| exit 1 | |
| ;; | |
| *) | |
| echo "INFO: Garnix CI concluded with $conclusion" | |
| ;; | |
| esac | |