Skip to content

Commit

Permalink
Update python-package-conda.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
rcervinoucm authored May 31, 2024
1 parent 154b6f0 commit 79dd43c
Showing 1 changed file with 4 additions and 34 deletions.
38 changes: 4 additions & 34 deletions .github/workflows/python-package-conda.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,38 +36,8 @@ jobs:
run: |
conda install pytest
pytest
- name: Install pypa/build
run: >-
python3 -m
pip install
build
--user
- name: Build a binary wheel and a source tarball
run: python3 -m build
- name: Store the distribution packages
uses: actions/upload-artifact@v3
- name: Publish a Python distribution to PyPI
uses: ortega2247/pypi-upload-action@master
with:
name: python-package-distributions
path: dist/

publish-to-pypi:
name: >-
Publish Python 🐍 distribution 📦 to PyPI
if: startsWith(github.ref, 'refs/tags/') # only publish to PyPI on tag pushes
needs:
- build
runs-on: ubuntu-latest
environment:
name: pypi
url: https://pypi.org/p/ctlearn # Replace <package-name> with your PyPI project name
permissions:
id-token: write # IMPORTANT: mandatory for trusted publishing

steps:
- name: Download all the dists
uses: actions/download-artifact@v3
with:
name: python-package-distributions
path: dist/
- name: Publish distribution 📦 to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
user: __token__
password: ${{ secrets.PYPI_TOKEN }}

0 comments on commit 79dd43c

Please sign in to comment.