add build gh-action

Signed-off-by: Jonathan Irvin <djfoxyslpr@gmail.com>
This commit is contained in:
Jonathan Irvin 2024-09-07 13:28:29 -05:00
parent 11de46f5b3
commit f0fc916712
No known key found for this signature in database
1 changed files with 26 additions and 0 deletions

26
.github/build.yaml vendored Normal file
View File

@ -0,0 +1,26 @@
name: Build
on:
push:
branches: [$default-branch]
pull_request:
branches: [$default-branch]
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [20.x, 22.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- run: npm ci
- run: npm run build --if-present