forked from cvat-ai/cvat
-
Notifications
You must be signed in to change notification settings - Fork 0
31 lines (28 loc) · 911 Bytes
/
remark.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
name: Linter
on: pull_request
jobs:
Remark:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v2
with:
node-version: '16.x'
- name: Run checks
run: |
npm ci
mkdir -p remark_report
echo "Remark version: "`npx remark --version`
npx remark --quiet --report json --no-stdout . 2> ./remark_report/remark_report.json
get_report=`cat ./remark_report/remark_report.json | jq -r '.[] | select(.messages | length > 0)'`
if [[ ! -z ${get_report} ]]; then
pip install json2html
python ./tests/json_to_html.py ./remark_report/remark_report.json
exit 1
fi
- name: Upload artifacts
if: failure()
uses: actions/upload-artifact@v2
with:
name: remark_report
path: remark_report