8000 Deploy dev wheels to rackspace from travis by ogrisel · Pull Request #6768 · numpy/numpy · GitHub
[go: up one dir, main page]

Skip to content

Deploy dev wheels to rackspace from travis #6768

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Dec 11, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
ENH deploy dev wheels to rackspace
  • Loading branch information
ogrisel committed Dec 10, 2015
commit 27abfb4923a3ff0433bb7f5dd08a42603641b519
12 changes: 10 additions & 2 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,13 @@ matrix:
- python3-nose
- python: 2.7
env: NPY_RELAXED_STRIDES_CHECKING=0 PYTHON_OO=1
- python: 2.7
env: USE_WHEEL=1
- python: 3.5
env:
- USE_WHEEL=1
- WHEELHOUSE_UPLOADER_USERNAME=travis.numpy
# The following is generated with the command:
# travis encrypt -r numpy/numpy WHEELHOUSE_UPLOADER_SECRET=tH3AP1KeY
- secure: "IEicLPrP2uW+jW51GRwkONQpdPqMVtQL5bdroqR/U8r9TrXrbCVRhp4AP8JYZT0ptoBpmZWWGjmKBndB68QlMiUjQPowiFWt9Ka92CaqYdU7nqfWp9VImSndPmssjmCXJ1v1IjZPAMahp7Qnm0rWRmA0z9SomuRUQOJQ6s684vU="
- python: 2.7
env: PYTHONOPTIMIZE=2
before_install:
Expand All @@ -73,3 +78,6 @@ before_install:
8000
script:
- ./tools/travis-test.sh

after_success:
- ./tools/travis-upload-wheel.sh
8 changes: 5 additions & 3 deletions tools/travis-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -94,14 +94,16 @@ export PIP
if [ -n "$USE_WHEEL" ] && [ $# -eq 0 ]; then
# Build wheel
$PIP install wheel
# ensure that the pip / setuptools versions deployed inside the venv are recent enough
$PIP install -U virtualenv
$PYTHON setup.py bdist_wheel
# Make another virtualenv to install into
virtualenv --python=python venv-for-wheel
virtualenv --python=`which $PYTHON` venv-for-wheel
. venv-for-wheel/bin/activate
# Move out of source directory to avoid finding local numpy
pushd dist
$PIP install --pre --no-index --upgrade --find-links=. numpy
$PIP install nose
pip install --pre --no-index --upgrade --find-links=. numpy
pip install nose
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the --use-wheel option is actually not required but it does not hurt either. The pip command should be taken from the currently activate virtualenv instead of the $PIP env.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

--no-use-wheel is deprecated in pip 8.0, and --use-wheel isn't even listed in the help text of pip install anymore. So I wouldn't add it.

popd
run_test
elif [ "$USE_CHROOT" != "1" ]; then
Expand Down
11 changes: 11 additions & 0 deletions tools/travis-upload-wheel.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
#!/bin/bash
set -ex

export CLOUD_CONTAINER_NAME=travis-dev-wheels

if [[ ( $USE_WHEEL == 1 ) && \
( "$TRAVIS_BRANCH" == "master" ) && \
( "$TRAVIS_PULL_REQUEST" == "false" ) ]]; then
pip install wheelhouse_uploader
python -m wheelhouse_uploader upload --local-folder $TRAVIS_BUILD_DIR/dist/ $CLOUD_CONTAINER_NAME
fi
0