Skip to content

Commit dd79f8b

Browse files
authored
add changeset (#137)
1 parent a265b61 commit dd79f8b

File tree

4 files changed

+728
-105
lines changed

4 files changed

+728
-105
lines changed

.changeset/config.json

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"$schema": "https://unpkg.com/@changesets/config@3.0.0/schema.json",
3+
"changelog": "@changesets/cli/changelog",
4+
"commit": false,
5+
"fixed": [],
6+
"linked": [],
7+
"access": "public",
8+
"baseBranch": "main",
9+
"updateInternalDependencies": "patch",
10+
"ignore": []
11+
}

.github/workflows/publish.yaml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,17 @@ on:
33
release:
44
types: [published]
55
workflow_dispatch:
6+
push:
7+
branches: [main]
68
jobs:
7-
pnpm-publish:
9+
release:
810
runs-on: ubuntu-latest
11+
if: github.repository_owner == 'rphlmr'
912
steps:
1013
- name: ⬇️ Checkout repo
1114
uses: actions/checkout@v4
15+
with:
16+
fetch-depth: 0
1217

1318
- name: 👷 Install pnpm
1419
uses: pnpm/action-setup@v4
@@ -24,8 +29,13 @@ jobs:
2429
- name: 📥 Install dependencies
2530
run: pnpm install --frozen-lockfile
2631

27-
- name: Publish 🚀
28-
shell: bash
29-
run: pnpm publish --access public --no-git-checks
32+
- name: 🦋 Create Release Pull Request or Publish
33+
id: changesets
34+
uses: changesets/action@v1
35+
with:
36+
publish: pnpm run release
37+
title: "chore: release package"
38+
commit: "chore: release package"
3039
env:
31-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
40+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
41+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

package.json

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,10 @@
6464
"check:fix": "biome check --fix .",
6565
"typecheck": "tsc",
6666
"validate": "npm run check && npm run tsc",
67-
"clear-all": "rm -rf node_modules pnpm-lock.yaml && find ./examples -type d -name 'node_modules' -exec rm -rf {} + && find ./examples -name 'pnpm-lock.yaml' -exec rm -f {} +"
67+
"clear-all": "rm -rf node_modules pnpm-lock.yaml && find ./examples -type d -name 'node_modules' -exec rm -rf {} + && find ./examples -name 'pnpm-lock.yaml' -exec rm -f {} +",
68+
"changeset": "changeset",
69+
"version": "changeset version",
70+
"release": "changeset publish"
6871
},
6972
"author": "",
7073
"license": "ISC",
@@ -89,6 +92,7 @@
8992
},
9093
"devDependencies": {
9194
"@biomejs/biome": "^1.9.4",
95+
"@changesets/cli": "^2.29.5",
9296
"@cloudflare/workers-types": "^4.20250405.0",
9397
"@types/bun": "^1.2.8",
9498
"@types/node": "^22.14.0",
@@ -101,8 +105,8 @@
101105
},
102106
"peerDependencies": {
103107
"@cloudflare/workers-types": "^4.20250317.0",
104-
"@types/react": "^18.3.10 || ^19.0.0",
105108
"@react-router/dev": "^7.2.0",
109+
"@types/react": "^18.3.10 || ^19.0.0",
106110
"miniflare": "^3.20241205.0",
107111
"react-router": "^7.2.0",
108112
"vite": "^6.0.0 || ^7.0.0",

0 commit comments

Comments
 (0)