Skip to content

fix: adapt CI job permissions to trusted publishing workflow #166

fix: adapt CI job permissions to trusted publishing workflow

fix: adapt CI job permissions to trusted publishing workflow #166

on:
push:
branches:
- main
name: release-please
jobs:
release-please:
runs-on: ubuntu-latest
outputs:
release_created: ${{ steps.release.outputs.release_created }}
steps:
- uses: GoogleCloudPlatform/release-please-action@v3
id: release
with:
release-type: python
package-name: snakemake-interface-executor-plugins
publish-pypi:
runs-on: ubuntu-latest
needs: release-please
permissions:
id-token: write
if: ${{ needs.release-please.outputs.release_created }}
steps:
- uses: actions/checkout@v4
- name: Install Pixi
uses: prefix-dev/setup-pixi@v0.8.3
with:
environments: publish
pixi-version: v0.42.1
- name: Build source and wheel distribution + check build
# this will build the source and wheel into the dist/ directory
run: |
pixi run --environment publish check-build
- name: Publish distribution to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
env:
PYPI_USERNAME: __token__
PYPI_PASSWORD: ${{ secrets.PYPI_TOKEN }}