-
Notifications
You must be signed in to change notification settings - Fork 0
37 lines (35 loc) Β· 1.12 KB
/
new-review.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
name: Handle case files
on:
issues:
types: [opened, edited]
jobs:
new-case-file:
runs-on: ubuntu-latest
permissions:
issues: write
pull-requests: write
steps:
- uses: actions/checkout@v4
- name: Install requirements
run: python3 -m pip install -r automation/requirements.txt
- name: Run parser
id: run_parser
run: |
python3 automation/issue.py 2>&1 | tee parser.log
result_code=${PIPESTATUS[0]}
echo "parser-output=$(cat parser.log)" >> $GITHUB_OUTPUT
exit $result_code
- name: Create Pull Request
uses: peter-evans/create-pull-request@v3
with:
token: ${{ secrets.PR_TOKEN }}
title: "New coffee case #${{ github.event.issue.number }}"
branch: new-case-${{ github.event.issue.number }}
delete-branch: true
body: |
Author: @${{ github.event.issue.user.login }}
Closes #${{ github.event.issue.number }}
${{join(steps.run_parser.outputs.*, '\n')}}
```
${{ github.event.issue.body }}
```