Skip to content

Commit 28ec32e

Browse files
authored
Add build and test workflow (#1)
* Add build and test workflow * Add PR to workflow triggers * Remove tsc
1 parent cc7f984 commit 28ec32e

File tree

3 files changed

+21
-12
lines changed

3 files changed

+21
-12
lines changed

Diff for: .github/workflows/build.yaml

+19
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
name: Build
2+
3+
on:
4+
- push
5+
- pull_request
6+
7+
jobs:
8+
build:
9+
runs-on: ubuntu-latest
10+
steps:
11+
- uses: actions/checkout@v3
12+
- name: Setup Node.js
13+
uses: actions/setup-node@v3
14+
with:
15+
node-version: 20.x
16+
cache: "npm"
17+
- run: npm ci
18+
- run: npm run build --if-present
19+
- run: npm test

Diff for: package-lock.json

-10
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Diff for: package.json

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,14 @@
66
"scripts": {
77
"build": "tsc",
88
"format": "prettier -w .",
9-
"test": "vitest"
9+
"test": "vitest run",
10+
"test:watch": "vitest"
1011
},
1112
"author": "haroldadmin",
1213
"license": "ISC",
1314
"devDependencies": {
1415
"@types/node": "^20.12.4",
1516
"prettier": "^3.2.5",
16-
"tsc": "^2.0.4",
1717
"typescript": "^5.4.3",
1818
"vitest": "^1.4.0"
1919
}

0 commit comments

Comments
 (0)