forked from paritytech/substrate
-
Notifications
You must be signed in to change notification settings - Fork 15
32 lines (30 loc) · 1.19 KB
/
polkadot-companion-labels.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
name: Check Polkadot Companion and Label
on:
pull_request:
types: [opened, synchronize]
jobs:
check_status:
runs-on: ubuntu-latest
steps:
- name: Monitor the status of the gitlab-check-companion-build job
uses: s3krit/[email protected]
id: 'check-companion-status'
with:
authToken: ${{ secrets.GITHUB_TOKEN }}
ref: ${{ github.event.pull_request.head.sha }}
contexts: 'continuous-integration/gitlab-check-dependent-polkadot'
timeout: 1800
notPresentTimeout: 3600 # It can take quite a while before the job starts on Gitlab when the CI queue is large
failureStates: failure
interruptedStates: error # Error = job was probably cancelled. We don't want to label the PR in that case
pollInterval: 30
- name: Label success
uses: andymckay/labeler@master
if: steps.check-companion-status.outputs.result == 'success'
with:
remove-labels: 'A7-needspolkadotpr'
- name: Label failure
uses: andymckay/labeler@master
if: steps.check-companion-status.outputs.result == 'failure'
with:
add-labels: 'A7-needspolkadotpr'