Skip to content

Commit

Permalink
cleanup travis so pypi deploys are now only on tags
Browse files Browse the repository at this point in the history
  • Loading branch information
lheagy committed Dec 5, 2017
1 parent 806e92d commit 3f28b6c
Showing 1 changed file with 11 additions and 12 deletions.
23 changes: 11 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -42,15 +42,15 @@ after_success:

- bash <(curl -s https://codecov.io/bash)

# early exit if not on a deplotment branch
# - if ! [ "$TRAVIS_BRANCH" = "$MASTER_BRANCH" -o "$TRAVIS_TAG" = "true" ]; then
# echo "Not deploying (because this is not a deployment branch)" ;
# exit 0 ;
# fi
# - if [ "$TRAVIS_PULL_REQUEST" = "true" ]; then
# echo "Not deploying (because this is a pull request)" ;
# exit 0 ;
# fi
# early exit if not on a deplotment branch
- if ! [ "$TRAVIS_BRANCH" = "$MASTER_BRANCH" -o "$TRAVIS_TAG" = "true" ]; then
echo "Not deploying (because this is not a deployment branch)" ;
exit 0 ;
fi
- if [ "$TRAVIS_PULL_REQUEST" = "true" ]; then
echo "Not deploying (because this is a pull request)" ;
exit 0 ;
fi

# unpack credentials
- openssl aes-256-cbc -K $encrypted_5813a1339455_key -iv $encrypted_5813a1339455_iv -in credentials.tar.gz.enc -out credentials.tar.gz -d
Expand All @@ -59,10 +59,9 @@ after_success:
# deploy to pypi on tags
- if [ "$TRAVIS_TAG" = "true" -o "$TRAVIS_BRANCH" = "ref/travis" ]; then
mv credentials/.pypirc ~/.pypirc ;
python setup.py bdist_wheel --universal ;
travis_wait 20 twine upload --skip-existing dist/* ;
python setup.py sdist bdist_wheel --universal ;
travis_wait 20 twine upload -r pypi --skip-existing dist/* ;
fi
# travis_wait 20 python setup.py sdist upload -r pypi ;


notifications:
Expand Down

0 comments on commit 3f28b6c

Please sign in to comment.