Skip to content

Commit 878c869

Browse files
sloriablueyed
authored andcommitted
build: use Travis build stage to release to PyPI (#562)
See #473 (comment)
1 parent 5da0935 commit 878c869

File tree

2 files changed

+15
-21
lines changed

2 files changed

+15
-21
lines changed

.travis.yml

+15-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ sudo: false
22
language: python
33
dist: trusty
44

5-
matrix:
5+
jobs:
66
fast_finish: true
77
include:
88
- python: 3.6
@@ -34,6 +34,20 @@ matrix:
3434
- python: 3.6
3535
env: TOXENV=checkqa
3636

37+
- stage: PyPI Release
38+
if: tag IS present
39+
script: skip
40+
install: skip
41+
after_success: skip
42+
deploy:
43+
provider: pypi
44+
user: blueyed
45+
password:
46+
secure: "FY7qbX/N0XRcH8hVk00SsQWvNIkuxKvY7Br4ghRnHvleHG3YulJ7WbJnik+9eoBGeMfJeNyzBfVjpeo1ZIq9IZBiyTdNfG/sZFsC5LOoG/CPxPH3nD9JktI2HoBMnlSbGg/MMHjY+wXuOY647U/3qNedcnQmGztYt6QWi5DRxu8="
47+
on:
48+
tags: true
49+
distributions: "sdist bdist_wheel"
50+
3751
allow_failures:
3852
- env: TOXENV=py36-djmaster-postgres
3953

tox.ini

-20
Original file line numberDiff line numberDiff line change
@@ -65,23 +65,3 @@ deps =
6565
readme_renderer
6666
commands =
6767
python setup.py check -r -s
68-
69-
# Release tooling
70-
[testenv:build]
71-
basepython = python3.6
72-
skip_install = true
73-
deps =
74-
wheel
75-
setuptools
76-
commands =
77-
python setup.py -q sdist bdist_wheel
78-
79-
[testenv:release]
80-
basepython = python3.5
81-
skip_install = true
82-
deps =
83-
{[testenv:build]deps}
84-
twine >= 1.9.1
85-
commands =
86-
{[testenv:build]commands}
87-
twine upload -s --skip-existing dist/*

0 commit comments

Comments
 (0)