Skip to content

Set version and release #15

Set version and release

Set version and release #15

Workflow file for this run

name: Set version and release
on:
workflow_dispatch:
inputs:
version:
type: string
required: true
jobs:
upgrade:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.8.6'
- name: Install bumpver
run: pip install bumpver
- name: Check dry versioning with bumpver
run: bumpver update -n --set-version "${{ github.event.inputs.version }}"
- uses: EndBug/add-and-commit@v9
with:
default_author: user_info
message: 'Set version v${{ github.event.inputs.version }}'
pathspec_error_handling: exitImmediately
push: true
tag: 'v${{ github.event.inputs.version }}'
tag_push: '--force'
- uses: ncipollo/release-action@v1
with:
tag: "v${{ github.event.inputs.version }}"
name: "pactus v${{ github.event.inputs.version }}"
- name: Install tools for build and publish
run: pip install build twine
- name: Build
run: python -m build
- name: Publish
run: twine upload dist/* -u "__token__" -p "${{ secrets.PYPI_RELEASE_TOKEN }}"