@@ -1,37 +0,0 @@
1−name: "Wait for ofborg"
2−on:
3− pull_request:
4−jobs:
5− tests:
6− runs-on: ubuntu-latest
7− steps:
8− - name: Wait for ofborg CI
9− run: |
10− # Wait for ofborg ...
11− # eval sometimes takes a bit longer on staging.
12− if [[ "$BASE_BRANCH" == "staging" ]]; then
13− COUNTDOWN=$((COUNTDOWN*2))
14− fi
15− # ..in future a better fix would be to make ofborg mark CI as pending right away.
16− for i in $(seq "$COUNTDOWN"); do
17− res=$(curl --silent \
18− -H "Accept: application/vnd.github.antiope-preview+json" \
19− -H "Authorization: token ${GITHUB_TOKEN}" \
20− "https://api.github.com/repos/NixOS/nixpkgs/commits/${COMMIT}/check-runs" | \
21− jq ".check_runs | map(.app) | map(.id) | contains([${OFBORG_APP_ID}])")
22− if [[ "$res" == "true" ]]; then
23− exit 0
24− fi
25− sleep 5
26− echo "."
27− done
28− echo "Timeout!"
29− exit 1
30− # ofborg is not checking forks.
31− if: github.repository_owner == 'NixOS'
32− env:
33− BASE_BRANCH: ${{ github.base_ref }}
34− COUNTDOWN: 540 # wait for ~45min...
35− GITHUB_TOKEN: ${{ github.token }}
36− COMMIT: ${{ github.event.pull_request.head.sha }}
37− OFBORG_APP_ID: 20500