-
Notifications
You must be signed in to change notification settings - Fork 18
50 lines (43 loc) · 1.15 KB
/
build-frontend.yaml
File metadata and controls
50 lines (43 loc) · 1.15 KB
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
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
name: build-frontend
on:
push:
branches:
- 'master'
- 'main'
tags:
- 'v*'
pull_request:
merge_group:
workflow_dispatch:
inputs:
git-ref:
description: 'Git ref (optional)'
required: false
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
# This repo has tons of cruft in its history, so we try to only fetch files we actually need:
fetch-depth: 0
filter: 'blob:none'
- name: Use cached ~/.npm
uses: actions/cache@v4
with:
path: ~/.npm
key: ${{ runner.os }}-node-${{ matrix.variant }}-${{ hashFiles('**/package-lock.json') }}
restore-keys: ${{ runner.os }}-node
- name: Install build dependencies
working-directory: ./frontend
run: npm install
- name: Build
working-directory: ./frontend
run: |
export NODE_OPTIONS=--max_old_space_size=4096
CI=false npm run build
- name: Upload build output
uses: actions/upload-artifact@v4
with:
name: frontend
path: ./frontend/build