-
Notifications
You must be signed in to change notification settings - Fork 1
35 lines (31 loc) · 1001 Bytes
/
build.yaml
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
name: build
on: [push]
jobs:
build:
name: Build / Linux
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
with:
node-version: "16"
- uses: actions/cache@v3 # Source: https://gist.github.com/rupeshtiwari/44ebec690f2c01bf1df9b1d215a0e723
id: cache-nodemodules
env:
cache-name: cache-node-modules
with:
# caching node_modules
path: node_modules
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- if: steps.cache-nodemodules.outputs.cache-hit != 'true'
run: npm ci
- run: npm run prettier-check
- run: npm run lint
- run: npm run stylelint
- run: npm run test
- run: npm run build
- run: npm run build-prod