Skip to content

Update python-publish.yml #2

Update python-publish.yml

Update python-publish.yml #2

Workflow file for this run

name: Upload Python Package
on:
push:
tags:
- 'v*' # Questo attiva il workflow solo sui push dei tag che iniziano con "v"
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v2
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: '3.x'
- name: Install build dependencies
run: |
python -m pip install --upgrade pip
pip install build twine
- name: Build the package
run: python -m build
- name: List files for debugging
run: ls -l dist
- name: Publish to PyPI
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}
run: twine upload dist/*