Skip to content

chore: 杂项

chore: 杂项 #1

name: Public Packages
on:
push:
branches:
- master
workflow_dispatch:
permissions:
contents: write
jobs:
publish-npm:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup PNPM
uses: pnpm/action-setup@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
cache: pnpm
registry-url: https://registry.npmjs.org/
- name: Install dependencies
run: pnpm install
- name: Build Package
run: pnpm build
- name: Test Package
run: pnpm test
- name: Publish Package
run: pnpm release
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
- name: Push Tag
run: git push origin --tags
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}