release: build wheel
This commit is contained in:
parent
f8cce32562
commit
f72d91672e
|
@ -26,7 +26,7 @@ matrix:
|
||||||
env: TOXENV=py35
|
env: TOXENV=py35
|
||||||
dist: precise
|
dist: precise
|
||||||
- python: 3.6
|
- python: 3.6
|
||||||
env: TOXENV=py36 BDIST=1
|
env: TOXENV=py36 BDIST=1 WHEEL=1
|
||||||
- python: 3.6
|
- python: 3.6
|
||||||
env: TOXENV=individual_coverage
|
env: TOXENV=individual_coverage
|
||||||
- language: node_js
|
- language: node_js
|
||||||
|
|
|
@ -148,6 +148,16 @@ def build():
|
||||||
|
|
||||||
os.makedirs(DIST_DIR, exist_ok=True)
|
os.makedirs(DIST_DIR, exist_ok=True)
|
||||||
|
|
||||||
|
if "WHEEL" in os.environ:
|
||||||
|
print("Building wheel...")
|
||||||
|
subprocess.check_call(
|
||||||
|
[
|
||||||
|
"python",
|
||||||
|
"setup.py", "-q", "bdist_wheel",
|
||||||
|
"--dist-dir", "release/dist",
|
||||||
|
]
|
||||||
|
)
|
||||||
|
|
||||||
for bdist, tools in sorted(BDISTS.items()):
|
for bdist, tools in sorted(BDISTS.items()):
|
||||||
with Archive(join(DIST_DIR, archive_name(bdist))) as archive:
|
with Archive(join(DIST_DIR, archive_name(bdist))) as archive:
|
||||||
for tool in tools:
|
for tool in tools:
|
||||||
|
|
15
tox.ini
15
tox.ini
|
@ -32,21 +32,8 @@ deps =
|
||||||
commands =
|
commands =
|
||||||
python test/individual_coverage.py
|
python test/individual_coverage.py
|
||||||
|
|
||||||
[testenv:wheel]
|
|
||||||
recreate = True
|
|
||||||
deps =
|
|
||||||
commands =
|
|
||||||
python setup.py -q bdist_wheel --dist-dir release/dist
|
|
||||||
pip install {posargs} release/dist/mitmproxy-{env:VERSION:}-py3-none-any.whl
|
|
||||||
# skip `mitmproxy --version` if SKIP_MITMPROXY is defined.
|
|
||||||
{env:SKIP_MITMPROXY:mitmproxy --version}
|
|
||||||
mitmdump --version
|
|
||||||
mitmweb --version
|
|
||||||
pathod --version
|
|
||||||
pathoc --version
|
|
||||||
|
|
||||||
[testenv:cibuild]
|
[testenv:cibuild]
|
||||||
passenv = TRAVIS_TAG TRAVIS_BRANCH AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY APPVEYOR_REPO_TAG_NAME APPVEYOR_REPO_TAG APPVEYOR_REPO_BRANCH RTOOL_KEY
|
passenv = TRAVIS_TAG TRAVIS_BRANCH AWS_ACCESS_KEY_ID AWS_SECRET_ACCESS_KEY APPVEYOR_REPO_TAG_NAME APPVEYOR_REPO_TAG APPVEYOR_REPO_BRANCH RTOOL_KEY WHEEL
|
||||||
deps =
|
deps =
|
||||||
-rrequirements.txt
|
-rrequirements.txt
|
||||||
pyinstaller==3.3.1
|
pyinstaller==3.3.1
|
||||||
|
|
Loading…
Reference in New Issue