Skip to content

Commit 2b851c8

Browse files
committed
build: github actions add
1 parent 97ce980 commit 2b851c8

File tree

2 files changed

+36
-1
lines changed

2 files changed

+36
-1
lines changed

.github/workflows/release.yml

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Release
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
8+
concurrency: ${{ github.workflow }}-${{ github.ref }}
9+
10+
jobs:
11+
release:
12+
name: Release
13+
runs-on: ubuntu-latest
14+
steps:
15+
- name: Checkout Repo
16+
uses: actions/checkout@v3
17+
18+
- name: Setup Node.js 20.x
19+
uses: actions/setup-node@v3
20+
with:
21+
node-version: 20.x
22+
23+
- name: Install Dependencies
24+
run: yarn
25+
26+
- name: Create Release Pull Request
27+
uses: changesets/action@v1
28+
with:
29+
version: yarn version
30+
publish: yarn publish
31+
env:
32+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
33+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,9 @@
88
"lint": "turbo lint",
99
"test": "turbo run test",
1010
"test:watch": "turbo run test:watch",
11-
"format": "prettier --write \"**/*.{ts,tsx,md}\""
11+
"format": "prettier --write \"**/*.{ts,tsx,md}\"",
12+
"version": "changeset version",
13+
"publish": "changeset publish"
1214
},
1315
"devDependencies": {
1416
"@changesets/cli": "^2.27.9",

0 commit comments

Comments
 (0)