chore: improve cd

This commit is contained in:
zernonia 2024-11-04 14:43:40 +08:00
parent 3646203d4f
commit df60e15a97
2 changed files with 15 additions and 3 deletions

View File

@ -15,12 +15,23 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup (Install Node & pnpm) - name: Setup (Install Node & pnpm)
uses: ./.github/actions/setup uses: ./.github/actions/setup
- name: Install dependencies
run: pnpm i --frozen-lockfile
- name: Build CLI & Publish to npm
run: pnpm --filter shadcn-vue pub:release
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- name: Build Module & Publish to npm
run: pnpm --filter shadcn-nuxt pub:release
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
- run: pnpm dlx changelogithub - run: pnpm dlx changelogithub
env: env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

View File

@ -32,7 +32,8 @@
"lint": "eslint .", "lint": "eslint .",
"test": "vitest run", "test": "vitest run",
"test:watch": "vitest watch", "test:watch": "vitest watch",
"release": "pnpm run prepack && pnpm publish && git push --follow-tags" "release": "pnpm run prepack && pnpm publish && git push --follow-tags",
"pub:release": "pnpm prepack && pnpm publish --no-git-checks --access public"
}, },
"dependencies": { "dependencies": {
"@nuxt/kit": "^3.12.4", "@nuxt/kit": "^3.12.4",