diff --git a/.github/workflows/pythonpublish.yml b/.github/workflows/pythonpublish.yml index 5aced50c..05423de4 100644 --- a/.github/workflows/pythonpublish.yml +++ b/.github/workflows/pythonpublish.yml @@ -1,33 +1,43 @@ name: Upload Python Package on: push: tags: - dulwich-* + branches: + - master jobs: deploy: runs-on: ${{ matrix.os }} strategy: matrix: os: [ubuntu-latest, macos-latest, windows-latest] python-version: ['3.x'] steps: - uses: actions/checkout@v2 - name: Set up Python ${{ matrix.python-version }} uses: actions/setup-python@v2 with: python-version: ${{ matrix.python-version }} - name: Install dependencies run: | python -m pip install --upgrade pip pip install setuptools wheel twine fastimport - - name: Build and publish + - name: Build + run: | + python setup.py sdist bdist_wheel + mkdir wheelhouse + mv dist/*.whl wheelhouse + if: "matrix.os != 'ubuntu-latest'" + - name: Build and publish (Linux) + uses: RalfG/python-wheels-manylinux-build@v0.2.2 + if: "matrix.os == 'ubuntu-latest'" + - name: Publish env: TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }} TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} run: | - python setup.py sdist bdist_wheel - twine upload dist/* + echo twine upload wheelhouse/*