-
Notifications
You must be signed in to change notification settings - Fork 18
43 lines (36 loc) · 1.05 KB
/
Relevance-challenge.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
33
34
35
36
37
38
39
40
41
42
43
name: relevance-challenge
on:
workflow_dispatch:
pull_request:
branches:
- main
jobs:
test:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: "3.10"
- name: Install dependencies
run: |
pip install -r requirements.txt
- name: Run checks
id: checks
run: |
output=$(python test.py ${{ secrets.TEST_FIILE_URL }})
echo "output=$output" >> $GITHUB_OUTPUT
- name: Publish output to comments
uses: actions/github-script@v6
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
const output = `#### Check Results: \`${{ steps.checks.outputs.output }}\`\n
*Pusher: @${{ github.actor }}*`;
github.rest.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: output
})