name: Build

on:
  push:
    branches:
      - version_2_2
      - ci_wheels
    tags:
      - v*

jobs:
  build_wheels:
    name: Build wheels on ${{ matrix.os }}
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
        #os: [ubuntu-20.04, windows-2019, macos-10.15]
        os: [windows-2019]

    steps:
      - uses: actions/checkout@v2

#      - name: Install Visual C++ for Python 2.7
#        if: runner.os == 'Windows'
#        run: choco install vcpython27 -f -y

      - name: Build wheels
        uses: joerick/cibuildwheel@v1.10.0
        # to supply options, put them in 'env', like:
        # env:
        #   CIBW_SOME_OPTION: value
        env:
          CIBW_SKIP: cp27-* pp27-*
          GITHUB_BUILDING_WHEELS: 1

      - uses: actions/upload-artifact@v2
        with:
          path: ./wheelhouse/*.whl

