fix: 🐛 修改github action #21
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: npm publish | |
on: | |
push: | |
tags: | |
- v* | |
permissions: | |
contents: write # This is required to create/push the new git tag | |
jobs: | |
publish: | |
if: github.event.repository.owner.id == github.event.sender.id | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Use Node.js | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 22.x | |
- name: Set Publishing Config | |
run: npm config set '//registry.npmjs.org/:_authToken' "${NPM_TOKEN}" | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
- name: npm publish | |
run: | | |
cd ./cli | |
# npm publish -r --tag latest --no-git-checks | |
env: | |
NPM_TOKEN: ${{ secrets.NPM_TOKEN }} | |
- name: Automatic Releases | |
uses: marvinpinto/[email protected] | |
with: | |
repo_token: "${{ secrets.GITHUB_TOKEN }}" | |
automatic_release_tag: "v0.0.5" | |
prerelease: false | |
title: "Development Build" | |