Skip to content

Commit b5829b1

Browse files
committed
feat: update
1 parent 32705a8 commit b5829b1

File tree

2 files changed

+32
-2
lines changed

2 files changed

+32
-2
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
name: Prepare Publish npm packages
2+
on:
3+
push:
4+
branches:
5+
- '**' # 匹配所有分支
6+
7+
jobs:
8+
publish:
9+
runs-on: ubuntu-latest
10+
# 当具有 release 标签的 PR 被合并时,自动发布包版本
11+
12+
steps:
13+
- uses: actions/checkout@v3
14+
15+
- name: Install Node.js
16+
uses: actions/setup-node@v3
17+
with:
18+
node-version: 18
19+
20+
- name: Install pnpm and dependencies
21+
uses: pnpm/action-setup@v4
22+
with:
23+
version: 9
24+
run_install: false
25+
26+
- name: Publish
27+
env:
28+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
29+
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
30+
run: pnpm config set //registry.npmjs.org/:_authToken ${NPM_TOKEN} & pnpm run check:publish

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
"docs": "dumi dev",
1414
"version": "changeset version",
1515
"publish": "npm run prev && npm run build && pnpm publish -r --force",
16-
"check:publish": "pnpm store prune && rm -rf pnpm-lock.yaml && npm run prev && npm run build && pnpm publish -r --dry-run"
16+
"check:publish": "npm run prev && npm run build && pnpm publish -r --dry-run"
1717
},
1818
"husky": {
1919
"hooks": {
@@ -60,7 +60,7 @@
6060
"babel-loader": "^8.2.5",
6161
"css-loader": "^6.8.1",
6262
"dumi": "^2.2.17",
63-
"dumi-theme-antd": "latest",
63+
"dumi-theme-antd": "^0.4.2",
6464
"father": "^4.4.1",
6565
"file-loader": "^6.2.0",
6666
"fs-extra": "^10.1.0",

0 commit comments

Comments
 (0)