support Github Actions (#57)
This commit is contained in:
parent
e9154f9694
commit
78a76dd63b
3 changed files with 246 additions and 0 deletions
76
.github/workflows/build-darwin.yml
vendored
Normal file
76
.github/workflows/build-darwin.yml
vendored
Normal file
|
@ -0,0 +1,76 @@
|
|||
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@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"
|
||||
|
||||
- uses: actions/setup-python@v1
|
||||
name: Install Python 3.5
|
||||
with:
|
||||
python-version: "3.5"
|
||||
|
||||
- name: Install cibuildwheel
|
||||
run: |
|
||||
python -m pip install cibuildwheel==1.3.0
|
||||
|
||||
- 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.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: Test for Python 3.5
|
||||
run: |
|
||||
tox -e py35
|
||||
|
||||
- name: Build wheel
|
||||
if: contains(github.ref, 'tags/')
|
||||
run: |
|
||||
python -m cibuildwheel --output-dir wheelhouse
|
||||
env:
|
||||
CIBW_SKIP: cp27-* pp*
|
||||
|
||||
- uses: actions/upload-artifact@v1
|
||||
if: contains(github.ref, 'tags/')
|
||||
with:
|
||||
name: wheels
|
||||
path: ./wheelhouse
|
76
.github/workflows/build-linux.yml
vendored
Normal file
76
.github/workflows/build-linux.yml
vendored
Normal file
|
@ -0,0 +1,76 @@
|
|||
name: Build for Linux
|
||||
|
||||
on:
|
||||
- push
|
||||
- pull_request
|
||||
|
||||
jobs:
|
||||
build_wheels:
|
||||
name: Build wheel on Linux
|
||||
runs-on: ubuntu-18.04
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- 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"
|
||||
|
||||
- uses: actions/setup-python@v1
|
||||
name: Install Python 3.5
|
||||
with:
|
||||
python-version: "3.5"
|
||||
|
||||
- name: Install cibuildwheel
|
||||
run: |
|
||||
python -m pip install cibuildwheel==1.3.0
|
||||
|
||||
- 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.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: Test for Python 3.5
|
||||
run: |
|
||||
tox -e py35
|
||||
|
||||
- name: Build wheel
|
||||
if: contains(github.ref, 'tags/')
|
||||
run: |
|
||||
python -m cibuildwheel --output-dir wheelhouse
|
||||
env:
|
||||
CIBW_SKIP: cp27-* pp*
|
||||
|
||||
- uses: actions/upload-artifact@v1
|
||||
if: contains(github.ref, 'tags/')
|
||||
with:
|
||||
name: wheels
|
||||
path: ./wheelhouse
|
94
.github/workflows/build-windows.yml
vendored
Normal file
94
.github/workflows/build-windows.yml
vendored
Normal file
|
@ -0,0 +1,94 @@
|
|||
name: Build for windows
|
||||
|
||||
on:
|
||||
- push
|
||||
- pull_request
|
||||
|
||||
jobs:
|
||||
build_wheels:
|
||||
name: Build wheel on Windows ${{ matrix.config.arch }}
|
||||
runs-on: windows-latest
|
||||
strategy:
|
||||
matrix:
|
||||
config:
|
||||
- name: MSVC x64
|
||||
vs-arch: amd64
|
||||
py-architecture: x64
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
|
||||
- uses: actions/setup-python@v1
|
||||
name: Install Python 3.8
|
||||
with:
|
||||
python-version: "3.8"
|
||||
architecture: ${{ matrix.config.py-architecture }}
|
||||
|
||||
- uses: actions/setup-python@v1
|
||||
name: Install Python 3.7
|
||||
with:
|
||||
python-version: "3.7"
|
||||
architecture: ${{ matrix.config.py-architecture }}
|
||||
|
||||
- uses: actions/setup-python@v1
|
||||
name: Install Python 3.6
|
||||
with:
|
||||
python-version: "3.6"
|
||||
architecture: ${{ matrix.config.py-architecture }}
|
||||
|
||||
- uses: actions/setup-python@v1
|
||||
name: Install Python 3.5
|
||||
with:
|
||||
python-version: "3.5"
|
||||
architecture: ${{ matrix.config.py-architecture }}
|
||||
|
||||
- name: Install cibuildwheel
|
||||
run: |
|
||||
python -m pip install cibuildwheel==1.3.0
|
||||
|
||||
- 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.8
|
||||
shell: cmd
|
||||
run: |
|
||||
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\VsDevCmd.bat" -no_logo -arch=${{ matrix.config.vs-arch }}
|
||||
tox -e py38
|
||||
|
||||
- name: Test for Python 3.7
|
||||
shell: cmd
|
||||
run: |
|
||||
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\VsDevCmd.bat" -no_logo -arch=${{ matrix.config.vs-arch }}
|
||||
tox -e py37
|
||||
|
||||
- name: Test for Python 3.6
|
||||
shell: cmd
|
||||
run: |
|
||||
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\VsDevCmd.bat" -no_logo -arch=${{ matrix.config.vs-arch }}
|
||||
tox -e py36
|
||||
|
||||
- name: Test for Python 3.5
|
||||
shell: cmd
|
||||
run: |
|
||||
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\Common7\Tools\VsDevCmd.bat" -no_logo -arch=${{ matrix.config.vs-arch }}
|
||||
tox -e py35
|
||||
|
||||
- name: Build wheel
|
||||
if: contains(github.ref, 'tags/')
|
||||
run: |
|
||||
python -m cibuildwheel --output-dir wheelhouse
|
||||
env:
|
||||
CIBW_SKIP: cp27-* pp*
|
||||
|
||||
- uses: actions/upload-artifact@v1
|
||||
if: contains(github.ref, 'tags/')
|
||||
with:
|
||||
name: wheels
|
||||
path: ./wheelhouse
|
Loading…
Reference in a new issue