Skip to content

Commit a83aa28

Browse files
committed
release gh action
1 parent 5d73423 commit a83aa28

File tree

3 files changed

+32
-4
lines changed

3 files changed

+32
-4
lines changed

.github/workflows/default-storage.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
name: Default storage
22
on:
3-
push:
4-
branches:
5-
- main
63
pull_request:
74
jobs:
85
changes:

.github/workflows/release.yml

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Release
2+
on:
3+
push:
4+
branches: [main]
5+
jobs:
6+
release:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- name: Checkout
10+
uses: actions/checkout@v4
11+
- name: Setup project
12+
uses: ./.github/actions/setup-project
13+
- name: Install dependencies
14+
run: yarn
15+
- name: Setup git user
16+
run: |
17+
git config --global user.name ${{ secrets.GH_BOT_NAME }}
18+
git config --global user.email ${{ secrets.GH_BOT_EMAIL }}
19+
- name: Version or release packages
20+
uses: changesets/action@v1
21+
with:
22+
title: "release: version packages"
23+
commit: "release: version packages"
24+
setupGitUser: false
25+
publish: "yarn release:publish"
26+
version: "yarn release:version"
27+
env:
28+
GITHUB_TOKEN: ${{ secrets.GH_RELEASE_TOKEN }}
29+
NPM_TOKEN: ${{ secrets.NPM_RELEASE_TOKEN }}

package.json

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,9 @@
1515
"format:js": "prettier --write $(git ls-files '*.js' '*.json' '*.ts' '*.tsx' '*.yml' 'README.md')",
1616
"test:lint": "turbo run test:lint",
1717
"test:ts": "turbo run test:ts",
18-
"test:format": "prettier --check --loglevel warn $(git ls-files '*.js' '*.json' '*.ts' '*.tsx' '*.yml' 'README.md')"
18+
"test:format": "prettier --check --loglevel warn $(git ls-files '*.js' '*.json' '*.ts' '*.tsx' '*.yml' 'README.md')",
19+
"release:version": "changeset version",
20+
"release:publish": "changeset release"
1921
},
2022
"devDependencies": {
2123
"@changesets/cli": "^2.27.7",

0 commit comments

Comments
 (0)