chore: 同步主干最新变更到 2.x (#1457)
* 新增 NPM 发布工作流 自动执行 npm publish * 优化 NPM 自动发布工作流 * 优化 NPM 自动发布工作流 剔除 分支 commit 触发条件 * 优化 NPM 发布工作流 更改为 release 创建时触发
This commit is contained in:
parent
91ca6143ad
commit
6a7d364b13
18
.github/workflows/npm-publish.yml
vendored
Normal file
18
.github/workflows/npm-publish.yml
vendored
Normal file
@ -0,0 +1,18 @@
|
|||||||
|
name: Publish to NPM
|
||||||
|
|
||||||
|
on:
|
||||||
|
release:
|
||||||
|
types: [created]
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
publish-npm:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v3
|
||||||
|
- uses: actions/setup-node@v3
|
||||||
|
with:
|
||||||
|
node-version: 16
|
||||||
|
registry-url: https://registry.npmjs.org
|
||||||
|
- run: npm publish
|
||||||
|
env:
|
||||||
|
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
|
Loading…
Reference in New Issue
Block a user