2019-11-25 18:59:07 -08:00
|
|
|
# As written, this configuration will build your wheels on every
|
|
|
|
|
# commit, but will only push to PyPI on tagged commits.
|
|
|
|
|
|
|
|
|
|
language: python
|
|
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
|
include:
|
|
|
|
|
# perform a linux build
|
|
|
|
|
- services: docker
|
|
|
|
|
# and a mac build
|
|
|
|
|
- os: osx
|
|
|
|
|
language: shell
|
|
|
|
|
# and a windows build
|
|
|
|
|
- os: windows
|
|
|
|
|
language: shell
|
|
|
|
|
before_install:
|
|
|
|
|
- choco install python --version 3.8.0
|
|
|
|
|
- export PATH="/c/Python38:/c/Python38/Scripts:$PATH"
|
2020-03-06 10:30:16 +00:00
|
|
|
# make sure it's on PATH as 'python3'
|
|
|
|
|
- ln -s /c/Python38/python.exe /c/Python38/python3.exe
|
2019-11-25 18:59:07 -08:00
|
|
|
|
|
|
|
|
env:
|
|
|
|
|
global:
|
2020-01-18 11:15:40 +00:00
|
|
|
- TWINE_USERNAME=__token__
|
|
|
|
|
# Note: TWINE_PASSWORD is set to a PyPI API token in Travis settings
|
2019-11-25 18:59:07 -08:00
|
|
|
|
|
|
|
|
install:
|
2020-12-03 18:02:15 +00:00
|
|
|
- python3 -m pip install cibuildwheel==1.7.1
|
2019-11-25 18:59:07 -08:00
|
|
|
|
|
|
|
|
script:
|
|
|
|
|
# build the wheels, put them into './wheelhouse'
|
2020-02-26 22:10:31 +00:00
|
|
|
- python3 -m cibuildwheel --output-dir wheelhouse
|
2019-11-25 18:59:07 -08:00
|
|
|
|
|
|
|
|
after_success:
|
|
|
|
|
# if the release was tagged, upload them to PyPI
|
2020-02-27 20:30:02 +00:00
|
|
|
- |
|
|
|
|
|
if [[ $TRAVIS_TAG ]]; then
|
|
|
|
|
python3 -m pip install twine
|
|
|
|
|
python3 -m twine upload wheelhouse/*.whl
|
|
|
|
|
fi
|