Publish the package to PyPI #5
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Publish the package to PyPI | |
on: | |
workflow_dispatch: | |
jobs: | |
publish_pypi: | |
name: Publish package | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@v3 | |
- name: Checkout action repository | |
uses: actions/checkout@v3 | |
- name: Publish package | |
env: | |
PYPI_USERNAME: ${{ secrets.PYPI_USERNAME }} | |
PYPI_PASSWORD: ${{ secrets.PYPI_PASSWORD }} | |
run: | | |
python3 -m pip install --upgrade twine build | |
pushd common/python/ | |
python3 -m build | |
python3 -m twine upload -u $PYPI_USERNAME -p $PYPI_PASSWORD --repository pypi dist/* | |
popd |