-
Notifications
You must be signed in to change notification settings - Fork 1
39 lines (32 loc) · 991 Bytes
/
pr-validation.yml
File metadata and controls
39 lines (32 loc) · 991 Bytes
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
name: PR Validation
# Run on pull requests to the main branch
on:
pull_request:
branches:
- main
jobs:
build-validation:
name: Build Validation
runs-on: ubuntu-latest
steps:
# Check out the repository code
- name: Checkout repository
uses: actions/checkout@v2
# Set up Node.js environment
- name: Setup Node.js environment
uses: actions/setup-node@v5
with:
node-version: "22"
cache: "npm"
# Delete package-lock so that install will use latest non breaking
- name: Delete package-lock.json
run: rm package-lock.json
# Install project dependencies
- name: Install dependencies
run: npm install
# Build project to validate it compiles successfully
- name: Build project
run: npm run build
# Add a success message
- name: Build successful
run: echo "✅ Build completed successfully! The PR can be merged safely."