Skip to content

Build and publish CPython #1

Build and publish CPython

Build and publish CPython #1

name: Build and publish Python
on:
workflow_dispatch:
inputs:
python_version:
required: true
type: string
workflow_call:
inputs:
python_version:
required: true
type: string
jobs:
build:
name: Build ${{ inputs.python_version }}
uses: ./.github/workflows/build_python.yml
with:
python_version: ${{ inputs.python_version }}
publish:
name: Publish ${{ inputs.python_version }}
needs: build
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Download artifact
uses: actions/download-artifact@v3
with:
name: python
path: /tmp/python/
- name: Pick tag
run: |
echo "SELECTED_TAG=$(./scripts/pick_semver.sh ${{ inputs.python_version }})" >> $GITHUB_ENV
- name: Release
uses: softprops/action-gh-release@v1
with:
files: /tmp/python/python*.tar.gz
tag_name: ${{ env.SELECTED_TAG }}
body: "Python ${{ inputs.python_version }}"