2021-07-09 06:19:58 +00:00
|
|
|
name: Client
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
paths:
|
|
|
|
- "client/**"
|
|
|
|
pull_request:
|
|
|
|
paths:
|
|
|
|
- "client/**"
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
client-build:
|
|
|
|
name: Build
|
2021-07-09 13:31:15 +00:00
|
|
|
runs-on: ubuntu-latest
|
2021-07-09 06:19:58 +00:00
|
|
|
|
|
|
|
defaults:
|
|
|
|
run:
|
|
|
|
working-directory: ./client
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Checkout code
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: Setup Node
|
|
|
|
uses: actions/setup-node@v2.1.5
|
|
|
|
with:
|
2021-07-09 13:31:15 +00:00
|
|
|
node-version: 14.x
|
2021-07-09 06:19:58 +00:00
|
|
|
|
|
|
|
- name: Get yarn cache directory path
|
|
|
|
id: yarn-cache-dir-path
|
|
|
|
run: echo "::set-output name=dir::$(yarn cache dir)"
|
|
|
|
|
|
|
|
- name: cache node_modules
|
|
|
|
uses: actions/cache@v2
|
|
|
|
with:
|
|
|
|
path: ${{ steps.yarn-cache-dir-path.outputs.dir }}
|
|
|
|
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }}
|
|
|
|
restore-keys: |
|
|
|
|
${{ runner.os }}-yarn-
|
|
|
|
|
|
|
|
- name: Installling dependencies
|
|
|
|
if: steps.cache.outputs.cache-hit != 'true'
|
|
|
|
run: yarn
|
|
|
|
|
|
|
|
- name: Lint
|
|
|
|
run: yarn lint
|
|
|
|
|
|
|
|
- name: Build
|
|
|
|
run: yarn build
|
|
|
|
|
|
|
|
- name: Initialize CodeQL
|
|
|
|
uses: github/codeql-action/init@v1
|
|
|
|
with:
|
|
|
|
languages: javascript
|
|
|
|
|
|
|
|
- name: Perform CodeQL Analysis
|
|
|
|
uses: github/codeql-action/analyze@v1
|