-
Notifications
You must be signed in to change notification settings - Fork 37
46 lines (36 loc) · 1.14 KB
/
checkTutorialDescription.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
44
45
name: Auto review tutorial description
on:
pull_request_target:
workflow_dispatch:
jobs:
auto_review:
runs-on: ubuntu-latest
env:
PR_NUMBER: ${{github.event.number}}
steps:
- name: Checkout playbooks
uses: actions/checkout@v2
- name: Checkout tutorial-compiler
uses: actions/checkout@v2
with:
repository: devonfw-tutorials/tutorial-compiler
path: tutorial-compiler
- name: Install node environment
uses: actions/setup-node@v2-beta
- name: npm install
run: npm install
- name: Check tutorial descriptions
run: node autoReviewPullRequest.js
- name: Get message
id: get_message
run: |
message=`cat message.txt`
echo ${message}
echo "::set-output name=message::$message"
- name: Request changes
if: ${{ steps.get_message.outputs.message != '' }}
uses: andrewmusgrave/[email protected]
with:
repo-token: '${{ secrets.GITHUB_TOKEN }}'
event: REQUEST_CHANGES
body: ${{ steps.get_message.outputs.message }}