pythonpublish.yml 809 B

123456789101112131415161718192021222324252627282930313233
  1. name: Upload Python Package
  2. on:
  3. push:
  4. tags:
  5. - dulwich-*
  6. jobs:
  7. deploy:
  8. runs-on: ${{ matrix.os }}
  9. strategy:
  10. matrix:
  11. os: [ubuntu-latest, macos-latest, windows-latest]
  12. python-version: ['3.x']
  13. steps:
  14. - uses: actions/checkout@v2
  15. - name: Set up Python ${{ matrix.python-version }}
  16. uses: actions/setup-python@v2
  17. with:
  18. python-version: ${{ matrix.python-version }}
  19. - name: Install dependencies
  20. run: |
  21. python -m pip install --upgrade pip
  22. pip install setuptools wheel twine fastimport
  23. - name: Build and publish
  24. env:
  25. TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
  26. TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
  27. run: |
  28. python setup.py sdist bdist_wheel
  29. twine upload dist/*