Skip to content

Commit

Permalink
Fix PyPi publishing (#217)
Browse files Browse the repository at this point in the history
* Fix PyPi publishing

* test

* test

* fix
  • Loading branch information
lukicdarkoo authored Feb 3, 2025
1 parent b8a65b7 commit d38e830
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 15 deletions.
35 changes: 21 additions & 14 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,23 +9,30 @@ on:

jobs:
deploy:

name: Upload release to PyPI
runs-on: ubuntu-latest


environment:
name: pypi
url: https://pypi.org/p/urdf2webots
permissions:
id-token: write
steps:
- uses: actions/checkout@v2
- name: Checkout repository
uses: actions/checkout@v3

- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v4
with:
python-version: '3.8'
- name: Install dependencies
python-version: '3.10'

- name: Install build tools
run: |
python -m pip install --upgrade pip
pip install setuptools wheel twine
- name: Build and publish
env:
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
run: |
python setup.py sdist bdist_wheel
twine upload dist/*
pip install build
- name: Build package
run: python -m build

- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
tests:
strategy:
matrix:
python: ['3.9', '3.10']
python: ['3.10', '3.12']
runs-on: ubuntu-latest
env:
CI: 1
Expand Down

0 comments on commit d38e830

Please sign in to comment.