Skip to content

Commit

Permalink
* Github Actions: remove unused pypi-publish job
Browse files Browse the repository at this point in the history
  • Loading branch information
hostcc committed Sep 18, 2024
1 parent 2adb7fd commit 98e8373
Showing 1 changed file with 0 additions and 40 deletions.
40 changes: 0 additions & 40 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,46 +72,6 @@ jobs:
-Dsonar.projectVersion=${{ steps.package-version.outputs.VALUE }}
# yamllint enable rule:line-length

pypi-publish:
name: Publish to PyPi
runs-on: ubuntu-latest
# PyPi disallows to publish packages with direct dependencies (GitHub
# sourced dependency in this case), so disable publishing for now
if: false
needs: [tests]
steps:
- name: Checkout the code
uses: actions/checkout@v3
with:
fetch-depth: 0 # `setuptools_scm` needs tags
- name: Set Python up
uses: actions/setup-python@v4
with:
python-version: 3.9
- name: Install the PEP517 package builder
run: python -m pip install --upgrade build
- name: Build the package
run: python -m build
- name: Publish the package to Test PyPi
# Skip publishing to test PyPI if we're performing release, there might
# be already the version of the package from the merge to master branch
if: github.event_name != 'release'
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.TEST_PYPI_TOKEN }}
repository_url: https://test.pypi.org/legacy/
- name: Publish the release to PyPi
# Publish to production PyPi only happens when a release published out
# of the main branch
if: >-
github.event_name == 'release'
&& github.event.action == 'published'
&& (github.event.release.target_commitish == 'main'
|| github.event.release.target_commitish == 'master')
uses: pypa/gh-action-pypi-publish@release/v1
with:
password: ${{ secrets.PYPI_TOKEN }}

docker-publish:
name: Build and publish Docker images
runs-on: ubuntu-latest
Expand Down

0 comments on commit 98e8373

Please sign in to comment.