2021-08-13 01:45:50 +08:00
|
|
|
name: CI - WebUI
|
2021-03-23 22:20:37 +08:00
|
|
|
|
|
|
|
on: [pull_request, push]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
check_webui:
|
|
|
|
name: Check WebUI
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
defaults:
|
|
|
|
run:
|
|
|
|
working-directory: src/webui/www
|
|
|
|
|
|
|
|
steps:
|
2021-08-13 01:49:47 +08:00
|
|
|
- name: checkout repository
|
|
|
|
uses: actions/checkout@v2
|
2021-03-23 22:20:37 +08:00
|
|
|
|
2021-08-13 01:49:47 +08:00
|
|
|
- name: setup nodejs
|
|
|
|
uses: actions/setup-node@v2
|
|
|
|
with:
|
|
|
|
node-version: '14'
|
2021-03-23 22:20:37 +08:00
|
|
|
|
2021-08-13 01:49:47 +08:00
|
|
|
- name: install tools
|
|
|
|
run: npm install
|
2021-03-23 22:20:37 +08:00
|
|
|
|
2021-08-13 01:49:47 +08:00
|
|
|
- name: lint code
|
|
|
|
run: npm run lint
|
2021-03-23 22:20:37 +08:00
|
|
|
|
2021-08-13 01:49:47 +08:00
|
|
|
- name: format code
|
|
|
|
run: |
|
|
|
|
npm run format
|
|
|
|
git diff --exit-code
|