name: Build for macOS on: - push - pull_request jobs: build_wheels: name: Build wheel on macOS runs-on: macos-latest steps: - uses: actions/checkout@v2 - uses: actions/setup-python@v2 name: Install Python 3.9 with: python-version: "3.9" - uses: actions/setup-python@v1 name: Install Python 3.8 with: python-version: "3.8" - uses: actions/setup-python@v1 name: Install Python 3.7 with: python-version: "3.7" - uses: actions/setup-python@v1 name: Install Python 3.6 with: python-version: "3.6" - name: Install cibuildwheel run: | python -m pip install cibuildwheel==1.6.3 - name: Checkout submodules shell: bash run: | git submodule sync --recursive git submodule update --init --force --recursive --depth=1 - name: Install dependencies run: | pip install -r requirements-dev.txt - name: Test for Python 3.9 run: | tox -e py39 - name: Test for Python 3.8 run: | tox -e py38 - name: Test for Python 3.7 run: | tox -e py37 - name: Test for Python 3.6 run: | tox -e py36 - name: Build wheel if: contains(github.ref, 'tags/') run: | python -m cibuildwheel --output-dir wheelhouse env: CIBW_BUILD: cp36-* cp37-* cp38-* cp39-* - uses: actions/upload-artifact@v1 if: contains(github.ref, 'tags/') with: name: wheels path: ./wheelhouse