2021-11-26 11:40:26 +08:00
|
|
|
name: MAIN_PULL_REQUEST
|
|
|
|
|
|
|
|
on:
|
|
|
|
pull_request:
|
|
|
|
branches: [develop, main]
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
MAIN_PULL_REQUEST:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2021-12-06 22:53:37 +08:00
|
|
|
- uses: actions/checkout@v2
|
2021-12-22 12:07:29 +08:00
|
|
|
- name: Cache nodemodules
|
|
|
|
uses: actions/cache@v2
|
|
|
|
env:
|
|
|
|
cache-name: cache-nodemodules
|
|
|
|
with:
|
|
|
|
path: ~/.npm
|
|
|
|
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package.json') }}
|
|
|
|
restore-keys: |
|
|
|
|
${{ runner.os }}-build-${{ env.cache-name }}-
|
|
|
|
${{ runner.os }}-build-
|
|
|
|
${{ runner.os }}-
|
2021-12-20 10:44:35 +08:00
|
|
|
- uses: actions/setup-node@v2
|
|
|
|
with:
|
|
|
|
node-version: '16'
|
2021-12-06 22:53:37 +08:00
|
|
|
- run: npm install
|
|
|
|
shell: bash
|
2021-12-12 01:04:13 +08:00
|
|
|
- run: npm run lint
|