Skip to content

Package Release

Package Release #28

Workflow file for this run

name: Package Release
on: workflow_dispatch
jobs:
publish:
runs-on: ubuntu-latest
permissions:
# IMPORTANT: This permission is mandatory for trusted publishing.
id-token: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
ref: ${{ github.head_ref || github.ref_name }}
token: ${{ secrets.GALILEO_AUTOMATION_GITHUB_TOKEN }}
- name: Python Semantic Release
id: release
uses: python-semantic-release/python-semantic-release@v9.17.0
with:
git_committer_name: galileo-automation
git_committer_email: ci@rungalileo.io
github_token: ${{ secrets.GALILEO_AUTOMATION_GITHUB_TOKEN }}
ssh_public_signing_key: ${{ secrets.GALILEO_AUTOMATION_SSH_PUBLIC_KEY }}
ssh_private_signing_key: ${{ secrets.GALILEO_AUTOMATION_SSH_PRIVATE_KEY }}
- name: Build Package
if: steps.release.outputs.released == 'true'
run: |
pipx install poetry==${{ vars.POETRY_VERSION }}
poetry build
- name: Publish Package to PyPI
if: steps.release.outputs.released == 'true'
uses: pypa/gh-action-pypi-publish@release/v1
with:
verbose: true
print-hash: true
- name: Publish to GitHub Releases
uses: python-semantic-release/upload-to-gh-release@main
if: steps.release.outputs.released == 'true'
with:
github_token: ${{ secrets.GALILEO_AUTOMATION_GITHUB_TOKEN }}