Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[QI2-1220] Extract PyPI upload via GH artifacts #97

Merged
merged 1 commit into from
Dec 23, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 31 additions & 5 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
name: Releases

on:
pull_request:
push:
branches:
- master
Expand All @@ -10,14 +9,41 @@ on:
- created

jobs:
publish:
name: Publish assets
docs-deploy:
name: Deploy docs
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v4
- uses: qutech-delft/github-actions/actions/docs/sphinx-docs-deploy@master
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
python-build:
name: Build Python package
runs-on: "ubuntu-latest"
steps:
- uses: actions/checkout@v4
- uses: qutech-delft/github-actions/actions/python/poetry-build@master
python-deploy:
name: Deploy Python package
runs-on: "ubuntu-latest"
needs: python-build
permissions:
id-token: write
contents: write
steps:
- uses: actions/checkout@v4
- uses: qutech-delft/github-actions/actions/python/poetry-release@master
- name: Download Artifact
uses: actions/download-artifact@v4
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
name: dist
path: dist
# Publishing the package
- name: Publish distribution 📦 to Test PyPI
if: github.ref == 'refs/heads/master'
uses: pypa/gh-action-pypi-publish@release/v1
with:
repository-url: https://test.pypi.org/legacy/
verbose: true
- name: Publish distribution 📦 to PyPI
if: github.event_name == 'release' && github.event.action == 'created'
uses: pypa/gh-action-pypi-publish@release/v1
Loading