Skip to content

Commit 5195e4f

Browse files
authored
Merge pull request #101 from chvmvd/add-build-test-github-actions
Add Build Test GitHub Actions
2 parents 29ad95b + 038538a commit 5195e4f

File tree

1 file changed

+33
-0
lines changed

1 file changed

+33
-0
lines changed

.github/workflows/build-test.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
---
2+
name: Build Test
3+
4+
on:
5+
pull_request:
6+
branches: [main, master]
7+
8+
jobs:
9+
build-test:
10+
name: Build Test
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Checkout Code
14+
uses: actions/checkout@v3
15+
16+
- name: Setup Node.js
17+
uses: actions/setup-node@v3
18+
with:
19+
node-version: latest
20+
21+
- name: Cache Node Modules
22+
uses: actions/cache@v3
23+
id: node_modules_cache_id
24+
with:
25+
path: "**/node_modules"
26+
key: ${{ runner.os }}-${{ hashFiles('**/package-lock.json') }}
27+
28+
- name: Install Node Modules
29+
if: steps.node_modules_cache_id.outputs.cache-hit != 'true'
30+
run: npm ci
31+
32+
- name: Build Test
33+
run: npm run build

0 commit comments

Comments
 (0)