-
Notifications
You must be signed in to change notification settings - Fork 1
45 lines (37 loc) · 1.01 KB
/
frontend-build.yml
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
name: Build
on:
push:
branches:
- main
paths:
- "frontend/**" # Only trigger on changes within this folder
- ".github/**"
pull_request:
paths:
- "frontend/**" # Only trigger on changes within this folder
- ".github/**"
workflow_dispatch:
jobs:
frontend-build-check:
name: Frontend Build Check
runs-on: ubuntu-latest
# Cache dependencies to speed up the workflow
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Set up Node.js
uses: actions/setup-node@v3
with:
node-version: "18"
- name: Enable Corepack
working-directory: ./frontend
run: corepack enable
- name: Set Yarn version to Berry
working-directory: ./frontend
run: corepack prepare yarn@4.2.2 --activate
- name: Install dependencies
working-directory: ./frontend
run: yarn install
- name: Run build
working-directory: ./frontend
run: yarn build