Skip to content

Prepare Release

Prepare Release #3

name: Prepare Release
on:
workflow_dispatch:
inputs:
version_update_type:
description: What type of version bump should be done
type: choice
options:
- patch
- minor
- major
jobs:
prepare:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Use Node.js 20.x
uses: actions/setup-node@v4
with:
node-version: 20.x
- name: Bump version
run: |
echo "new-version=$(npm version ${{ github.event.inputs.version_update_type }} --no-git-tag-version)" >> $GITHUB_OUTPUT
id: version
- name: Create Release PR
uses: peter-evans/create-pull-request@5e914681df9dc83aa4e4905692ca88beb2f9e91f # 7.0.5
with:
branch: release/${{ steps.version.outputs.new-version }}
title: 'chore: bump version to ${{ steps.version.outputs.new-version }}'
draft: false
body: An automated PR for next release.
commit-message: 'chore: bump version to ${{ steps.version.outputs.new-version }}'
labels: ignore-for-release