Skip to content

Site updated: 2023-09-30 21:08:39 #6

Site updated: 2023-09-30 21:08:39

Site updated: 2023-09-30 21:08:39 #6

Workflow file for this run

name: npm_publish
on:
push:
branches:
- main
jobs:
publish-npm:
runs-on: ubuntu-latest
# Clone 仓库
steps:
- name: Checkout
uses: actions/checkout@v2
with:
ref: master
# 安装 Node.js
- name: Setup Node
uses: actions/setup-node@v1
with:
node-version: "16"
registry-url: https://registry.npmjs.org/
# 发布 NPM 包
- name: Publish Package
run: |
npm init
git config --global user.email "zzy4on@outlook.com"
git config --global user.name "tobtobtob"
npm version patch
npm publish
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}