diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 72867ff..88de51e 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -18,9 +18,6 @@ jobs: with: node-version: "20" - - name: Install jq - run: sudo apt-get install -y jq - - name: Install pnpm run: | npm install -g pnpm @@ -37,14 +34,16 @@ jobs: - name: Install dependencies run: pnpm install - - name: Update version in package.json - if: github.ref_type == 'branch' - run: | - jq --arg build "$GITHUB_RUN_NUMBER" --arg commit "${GITHUB_SHA::8}" \ - '.version = .version + "-dev." + $build + "+" + $commit' package.json > package.json.tmp - mv package.json.tmp package.json - - - name: Release + - name: Run semantic-release env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} run: pnpm run release + + - name: Create Pull Request + uses: peter-evans/create-pull-request@v3 + with: + token: ${{ secrets.GITHUB_TOKEN }} + branch: release-branch + commit-message: "chore: create release PR" + title: "Release PR" + body: "This PR is automatically generated by semantic-release."