Skip to content

Prepare release PR

Prepare release PR #17

name: Prepare release PR
on:
workflow_dispatch:
inputs:
branch:
description: 'Branch to base the release from'
required: false
default: 'main'
bump:
description: |
'Release type: major, minor or patch. '
'Leave empty for autommatic detection based on changelog segments.'
required: false
default: ''
prerelease:
description: 'Prerelease (ex: rc1). Leave empty if not a pre-release.'
required: false
default: ''
# Set permissions at the job level.
permissions: {}
env:
FORCE_COLOR: "1"
jobs:
build:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version-file: .python-version-default
cache: pip
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install --upgrade setuptools tox
- name: Prepare release PR
run: |
tox -e prepare-release-pr -- ${{ github.event.inputs.branch }} ${{ github.token }} --bump='${{ github.event.inputs.bump }}' --prerelease='${{ github.event.inputs.prerelease }}'