Skip to content

Commit

Permalink
build: try fix release-please
Browse files Browse the repository at this point in the history
  • Loading branch information
pionxzh committed Mar 2, 2024
1 parent 7eda0e8 commit add08c5
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 14 deletions.
19 changes: 6 additions & 13 deletions .github/workflows/release-please.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,42 +10,35 @@ permissions:
pull-requests: write

jobs:
release-please:
release:
runs-on: ubuntu-latest
steps:
- uses: google-github-actions/release-please-action@v4
id: release
with:
release-type: node
include-component-in-tag: true
config-file: ./release-please-config.json
manifest-file: ./.release-please-manifest.json

publish:
runs-on: ubuntu-latest
needs: release
if: needs.release.outputs.release_created
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
if: ${{ steps.release.outputs.release_created }}

- name: Install pnpm
uses: pnpm/action-setup@v3
if: ${{ steps.release.outputs.release_created }}

- name: Use Node.js v20
uses: actions/setup-node@v4
with:
node-version: '20'
cache: pnpm
if: ${{ steps.release.outputs.release_created }}

- run: pnpm install
if: ${{ steps.release.outputs.release_created }}

- name: Build
run: pnpm run build
if: ${{ steps.release.outputs.release_created }}

- name: Publish
run: pnpm --filter "unminify" --filter "unpacker" --filter "cli" publish -r --access public
env:
NODE_AUTH_TOKEN: ${{secrets.NPM_TOKEN}}
if: ${{ steps.release.outputs.release_created }}
5 changes: 4 additions & 1 deletion release-please-config.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
{
"$schema": "https://raw.githubusercontent.com/googleapis/release-please/main/schemas/config.json",
"pull-request-title-pattern": "chore: release ${version}",
"bump-minor-pre-major": true,
"bump-patch-for-minor-pre-major": true,
"monorepoTags": true,
"release-type": "node",
"monorepo-tags": true,
"include-component-in-tag": true,
"packages": {
"packages/cli": {
"component": "cli"
Expand Down

0 comments on commit add08c5

Please sign in to comment.