Skip to content

Commit 14b2b06

Browse files
authored
Update tooling (#140)
2 parents 192ed4d + 61a7956 commit 14b2b06

File tree

8 files changed

+4508
-8281
lines changed

8 files changed

+4508
-8281
lines changed

.eslintrc.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
"dist",
1313
"output",
1414
"esbuild.config.mjs",
15-
"vite.config.ts"
15+
"vitest.config.ts"
1616
],
1717
"parserOptions": {
1818
"project": "./tsconfig.json"

.github/workflows/build.yml

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
name: build
22
on:
3+
pull_request:
34
push:
5+
branches:
6+
- main
47

58
jobs:
69
build:
@@ -13,26 +16,29 @@ jobs:
1316
node-version: [18.x, 20.x]
1417
steps:
1518
- uses: actions/checkout@v4
19+
- uses: pnpm/action-setup@v2
20+
with:
21+
version: 8
1622
- name: Use Node.js ${{ matrix.node-version }}
17-
uses: actions/setup-node@v3
23+
uses: actions/setup-node@v4
1824
with:
1925
node-version: ${{ matrix.node-version }}
20-
cache: npm
21-
- run: npm ci
26+
cache: pnpm
27+
- run: pnpm i
2228
- name: types
2329
run: npm run check:types
2430
- name: build
25-
run: npm run build
31+
run: pnpm run build
2632
- name: test
2733
id: test
2834
if: ${{ always() }}
29-
run: npm run test
35+
run: pnpm run test
3036
- name: lint
3137
if: ${{ always() }}
32-
run: npm run lint
38+
run: pnpm run lint
3339
- name: style
3440
if: ${{ always() }}
35-
run: npm run format:check
41+
run: pnpm run format:check
3642

3743
codecov: # Send only a single coverage report per run
3844
needs: build
@@ -42,13 +48,15 @@ jobs:
4248
runs-on: ubuntu-latest
4349
steps:
4450
- uses: actions/checkout@v4
45-
- name: Use Node.js lts
46-
uses: actions/setup-node@v3
51+
- uses: pnpm/action-setup@v2
52+
with:
53+
version: 8
54+
- uses: actions/setup-node@v4
4755
with:
4856
node-version: 20.x
49-
cache: npm
50-
- run: npm ci
57+
cache: pnpm
58+
- run: pnpm i
5159
- name: test
52-
run: npm run test:coverage
60+
run: pnpm run test:coverage
5361
- name: codecov
5462
uses: codecov/codecov-action@v3

.github/workflows/release.yml

Lines changed: 13 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -24,36 +24,37 @@ jobs:
2424
- uses: actions/checkout@v4
2525
with:
2626
fetch-depth: 0 # Need history for changelog generation
27-
- name: Use Node.js lts
28-
uses: actions/setup-node@v3
27+
- uses: pnpm/action-setup@v2
28+
with:
29+
version: 8
30+
- uses: actions/setup-node@v4
2931
with:
3032
node-version: 20.x
31-
cache: npm
32-
registry-url: https://registry.npmjs.org
33-
- run: npm ci
33+
cache: pnpm
34+
- run: pnpm i
3435
- name: types
35-
run: npm run check:types
36+
run: pnpm run check:types
3637
- name: build
37-
run: npm run build
38+
run: pnpm run build
3839
- name: test
3940
id: test
4041
if: ${{ always() }}
41-
run: npm run test -- --coverage
42+
run: pnpm run test --coverage
4243
- name: lint
4344
if: ${{ always() }}
44-
run: npm run lint
45+
run: pnpm run lint
4546
- name: style
4647
if: ${{ always() }}
47-
run: npm run format:check
48+
run: pnpm run format:check
4849
- name: npm auth
49-
run: npm set "//registry.npmjs.org/:_authToken" ${{ env.NPM_TOKEN }}
50+
run: pnpm set "//registry.npmjs.org/:_authToken" ${{ env.NPM_TOKEN }}
5051
- name: config git user
5152
run: |
5253
git config --global user.name ${{ secrets.ACTION_GITHUB_USERNAME }};
5354
git config --global user.email ${{ secrets.ACTION_GITHUB_EMAIL }};
5455
- name: perform release
5556
run: |
56-
npm run release -- \
57+
pnpm run release \
5758
${{ github.event.inputs.version }} \
5859
--ci
5960
- name: codecov # Perform after version publishing

0 commit comments

Comments
 (0)