Skip to content

Commit bd0cb92

Browse files
committed
add CI workflow
1 parent 8efacea commit bd0cb92

File tree

2 files changed

+28
-0
lines changed

2 files changed

+28
-0
lines changed

.github/workflows/ci.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: CI
2+
3+
on:
4+
push:
5+
branches:
6+
- "main"
7+
pull_request: {}
8+
9+
jobs:
10+
checks:
11+
name: Pre-merge Checks
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
- uses: actions/setup-node@v4
16+
with:
17+
node-version: 20
18+
19+
- name: Setup
20+
run: npm ci
21+
22+
- name: Check formatting
23+
run: npm run format:check
24+
25+
- name: Test build
26+
run: npm run build

package.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@
1313
],
1414
"scripts": {
1515
"build": "tsup",
16+
"format": "prettier --write .",
17+
"format:check": "prettier --check .",
1618
"test": "echo \"Error: no test specified\" && exit 1"
1719
},
1820
"repository": {

0 commit comments

Comments
 (0)