diff --git a/.github/build-wheels.sh b/.github/build-wheels.sh index 391cf07..cd4dfc9 100755 --- a/.github/build-wheels.sh +++ b/.github/build-wheels.sh @@ -13,7 +13,7 @@ function repair_wheel { cd ./io # Compile wheels -for PYBIN in /opt/python/cp3[6-8]*/bin; do +for PYBIN in /opt/python/cp3[6-10]*/bin; do "${PYBIN}/pip" install . "${PYBIN}/pip" install pytest "${PYBIN}/pip" wheel /io/ --no-deps -w wheelhouse/ diff --git a/.github/workflows/python-publish.yml b/.github/workflows/python-publish.yml index 3be004b..e0b0a3d 100644 --- a/.github/workflows/python-publish.yml +++ b/.github/workflows/python-publish.yml @@ -10,30 +10,28 @@ on: jobs: deploy: - runs-on: ${{ matrix.os }} strategy: max-parallel: 2 matrix: - os: [ubuntu-latest] - python-version: [3.8] + os: [macos-latest, windows-latest] + python-version: [3.7, 3.8, 3.9, "3.10"] steps: - - uses: actions/checkout@v2 - - name: Set up Python - uses: actions/setup-python@v2 - with: - python-version: ${{ matrix.python-version }} - - name: Install dependencies - run: | - python -m pip install --upgrade pip - pip install -U setuptools wheel twine - - name: Build and publish - env: - TWINE_USERNAME: __token__ - TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} - run: | - python setup.py sdist bdist_wheel - ls ./dist/*.whl - twine upload dist/*.gz - twine upload dist/*.whl + - uses: actions/checkout@v2 + - name: Set up Python + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -U setuptools wheel twine + - name: Build and publish + env: + TWINE_USERNAME: __token__ + TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }} + run: | + python setup.py sdist bdist_wheel + ls ./dist/*.whl + twine upload dist/*.whl diff --git a/.github/workflows/python_publish_linux.yml b/.github/workflows/python_publish_linux.yml new file mode 100755 index 0000000..140c9bf --- /dev/null +++ b/.github/workflows/python_publish_linux.yml @@ -0,0 +1,40 @@ +# This is a basic workflow that is manually triggered + +name: Linux Build and Publish + +on: + release: + types: [created] + workflow_dispatch: + + +# A workflow run is made up of one or more jobs that can run sequentially or in parallel +jobs: + # This workflow contains a single job called "greet" + deploy: + # The type of runner that the job will run on + runs-on: ubuntu-latest + + # Steps represent a sequence of tasks that will be executed as part of the job + steps: + - name: Set up Python 3.7 + uses: actions/setup-python@v1 + with: + python-version: 3.7 + # Runs a single command using the runners shell + - uses: actions/checkout@v2 + - name: Make wheels + run: | + sudo docker run -e PLAT=manylinux2010_x86_64 -v ${{ github.workspace }}:/io quay.io/pypa/manylinux2010_x86_64 /io/.github/build-wheels.sh + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -U 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/*.gz + twine upload wheelhouse/*manylinux*