Skip to content

Commit

Permalink
ci: update package publishing workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
oleoneto committed Dec 31, 2023
1 parent 36d6cda commit a2792d5
Showing 1 changed file with 9 additions and 8 deletions.
17 changes: 9 additions & 8 deletions .github/workflows/pythonpublish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ jobs:
id: checkout_code
uses: actions/checkout@master

# Create a release
- name: Create release
id: create_release
uses: actions/create-release@v1
Expand All @@ -25,19 +24,21 @@ jobs:
draft: false
prerelease: false

# Install dependencies and push to PyPI
- name: Set up Python
uses: actions/setup-python@v1
uses: actions/setup-python@v4
with:
python-version: '3.x'

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Build and publish
pip install setuptools wheel twine build
- name: Build package
run: python -m build

- name: Publish package
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
python setup.py sdist bdist_wheel
twine upload dist/*
run: twine upload dist/*

0 comments on commit a2792d5

Please sign in to comment.