line This ensures that the python that installs is the same python that should execute the module (this sometimes isn't true on macOS because the python.org installs that cibuildwheel makes take precedence over the system versions) Fix #266
39 lines
945 B
YAML
39 lines
945 B
YAML
# 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"
|
|
|
|
env:
|
|
global:
|
|
- TWINE_USERNAME=__token__
|
|
# Note: TWINE_PASSWORD is set to a PyPI API token in Travis settings
|
|
|
|
install:
|
|
- python3 -m pip install cibuildwheel==1.1.0
|
|
|
|
script:
|
|
# build the wheels, put them into './wheelhouse'
|
|
- python3 -m cibuildwheel --output-dir wheelhouse
|
|
|
|
after_success:
|
|
# if the release was tagged, upload them to PyPI
|
|
- |
|
|
if [[ $TRAVIS_TAG ]]; then
|
|
python3 -m pip install twine
|
|
python3 -m twine upload wheelhouse/*.whl
|
|
fi
|