Skip to content

Support publishing to PyPI using the trusted publisher mechanism #20

Support publishing to PyPI using the trusted publisher mechanism

Support publishing to PyPI using the trusted publisher mechanism #20

Workflow file for this run

name: Release to PyPI
on:
release:
types: [ published ]
pull_request:
types: [ opened, synchronize, reopened ]
concurrency:
group: pypi-release
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: ${{ vars.PYTHON_VERSION }}
- name: Install Poetry
run: curl -sSL https://install.python-poetry.org | python3 -
# - name: Validate Release Version
# run: poetry version -s | grep -E "$(echo "$GITHUB_REF_NAME" | tr -d 'v')"
- name: Build Basilisp distributions
run: poetry build
- name: Upload build artifact
uses: actions/upload-artifact@v4
with:
path: dist/
if-no-files-found: error
release:
runs-on: ubuntu-latest
environment:
name: release
needs:
- build
# permissions:
# id-token: write
steps:
- name: Download build artifact
uses: actions/download-artifact@v4
with:
path: dist/
merge-multiple: true
- run: ls -laR
# g - name: Publish package distributions to PyPI
# uses: pypa/gh-action-pypi-publish@release/v1.12.2