Skip to content

Commit c1470ab

Browse files
authored
Merge pull request #19 from dan-tw/pull-request-workflow
Add a GitHub actions workflow that does test builds for pull requests
2 parents 457b9da + f2f6886 commit c1470ab

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed
Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
# The following workflow will run when a pull request is opened, synched or reopened
2+
# It's intent is to run a build of the package against the PR to ensure that it passes a code build check
3+
4+
name: test-build
5+
on: pull_request
6+
7+
jobs:
8+
9+
# This job will checkout the repo, install dependencies and then build the frontend package
10+
test-build-frontend-and-lib:
11+
runs-on: ubuntu-latest
12+
13+
# set out working directory
14+
defaults:
15+
run:
16+
working-directory: ./
17+
18+
# checkout, install node and run our npm commands to check code builds
19+
steps:
20+
21+
- name: Checkout repo
22+
uses: actions/checkout@v3
23+
24+
- name: Setup node
25+
uses: actions/setup-node@v3
26+
with:
27+
node-version: "16.x"
28+
29+
# install deps for frontend and library and build both
30+
- name: Install library and frontend deps and build
31+
working-directory: ./examples/typescript
32+
id: npm
33+
run: |
34+
npm ci
35+
npm run build-all

0 commit comments

Comments
 (0)