Skip to content

Commit 27e145f

Browse files
introduce travis jobs and configure egg builds them (#288)
1 parent 4bf98fc commit 27e145f

File tree

3 files changed

+78
-31
lines changed

3 files changed

+78
-31
lines changed

.travis.yml

Lines changed: 74 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,92 @@
11
language: python
22
sudo: false
3+
4+
stages:
5+
- linting
6+
- test
7+
- deploy
8+
9+
10+
credentials:
11+
- &pypi
12+
provider: pypi
13+
user: ronny
14+
password:
15+
secure: QGJhDXmfFDKysMJJV/ONGaHHzG/aImhU3DdhEP63d657iQSn/Cb4EG/l9YmVnRzpJ94nSDXZB8YwptR7rid0bOtidb32lxN8n6UiWILCXWeAN2FE+tT9/0xIct4HUJZ8OttD1gft/Di722Gy+s9PzFwjwrV4efkxCzgjfYOjkMeq3aO6NoG3ur0iZXJh7ODwLp4sRFep2NpIEaXm2qMdnnXpck6bJ1q/NtvPx9CAZivd9HYa0evg5j1ENTz1mXXafhgF+0vRCBXA33xJuysO6CKtk+2mizL1QHfosOERiKl9+zPyZw+VvSchbCVwgxrMSiRcpGag+4SegyHrj1M/2YqfFzMF/yuFGcqXl2VkEqlnBQOVMNW3Kdcmnm+caNbddnv+M384WFz4nV8nWjcsD5l27+XlMWfuvskDIvZKtVCXmmbtqgwM4tqoYd6uxbnooRfwINTGx8sNzKP10xkaesB3ZBCEpecOKA1AXUAZ74RfYWWExv6eIuVGwyIJmOcD8M/17N8g58GxxO+88gx50EuhyNiRjYZDUipfVydfJwBwpD+p695NixUMITuksucQftjHsQp+laGWJlDIPvFwI85wDJUYAyrzn6L1W+smkm1bGomuliW2MJfxeSZAmSk4CE5VOpIWQTBmDLR3pxBhcaqzwdd4mAWvMi/fpM4yJJI=
16+
317
python:
418
- '2.7'
519
- '3.4'
620
- '3.5'
721
- '3.6'
8-
#- '3.7'
922
env:
1023
- TOXENV=py-test
1124

12-
matrix:
25+
jobs:
1326
include:
14-
- python: '3.5'
15-
env: TOXENV=flake8
16-
- python: '3.5'
27+
- stage: linting
28+
name: check readme
29+
python: '3.6'
1730
env: TOXENV=check_readme
18-
- python: '2.7'
31+
# - stage: test
32+
# python: '3.7'
33+
# dist: xenial
34+
- stage: test
35+
python: '2.7'
1936
env: SELFINSTALL=1
20-
- python: '3.5'
37+
- stage: test
38+
python: '3.6'
2139
env: SELFINSTALL=1
22-
cache:
23-
files:
24-
- $HOME/.pip/cache
25-
- $Home/.cache/pip
26-
install: pip install tox
27-
script:
28-
- python testing/runtests_travis.py
2940

41+
- stage: linting
42+
python: '3.6'
43+
name: validate pre-commit
44+
env:
45+
install:
46+
- pip install pre-commit
47+
- pre-commit install-hooks
48+
script:
49+
- pre-commit run --all-files
3050

51+
- &deploy
52+
stage: deploy
53+
name: "modern distributions"
54+
python: '3.6'
55+
install:
56+
- pip install -U pip setuptools wheel
57+
script: skip
58+
deploy:
59+
<<: *pypi
60+
on:
61+
tags: true
62+
distributions: "sdist bdist_wheel"
3163

32-
credentials:
33-
- &pypi
34-
provider: pypi
35-
user: ronny
36-
password:
37-
secure: QGJhDXmfFDKysMJJV/ONGaHHzG/aImhU3DdhEP63d657iQSn/Cb4EG/l9YmVnRzpJ94nSDXZB8YwptR7rid0bOtidb32lxN8n6UiWILCXWeAN2FE+tT9/0xIct4HUJZ8OttD1gft/Di722Gy+s9PzFwjwrV4efkxCzgjfYOjkMeq3aO6NoG3ur0iZXJh7ODwLp4sRFep2NpIEaXm2qMdnnXpck6bJ1q/NtvPx9CAZivd9HYa0evg5j1ENTz1mXXafhgF+0vRCBXA33xJuysO6CKtk+2mizL1QHfosOERiKl9+zPyZw+VvSchbCVwgxrMSiRcpGag+4SegyHrj1M/2YqfFzMF/yuFGcqXl2VkEqlnBQOVMNW3Kdcmnm+caNbddnv+M384WFz4nV8nWjcsD5l27+XlMWfuvskDIvZKtVCXmmbtqgwM4tqoYd6uxbnooRfwINTGx8sNzKP10xkaesB3ZBCEpecOKA1AXUAZ74RfYWWExv6eIuVGwyIJmOcD8M/17N8g58GxxO+88gx50EuhyNiRjYZDUipfVydfJwBwpD+p695NixUMITuksucQftjHsQp+laGWJlDIPvFwI85wDJUYAyrzn6L1W+smkm1bGomuliW2MJfxeSZAmSk4CE5VOpIWQTBmDLR3pxBhcaqzwdd4mAWvMi/fpM4yJJI=
38-
39-
deploy:
40-
- <<: *pypi
41-
on:
42-
tags: true
64+
- &eggs
65+
<<: *deploy
66+
name: "python eggs 2.7"
4367
python: '2.7'
44-
distributions: "sdist bdist_wheel"
45-
- <<: *pypi
46-
on:
47-
tags: true
48-
distributions: "bdist_egg"
68+
distributions: "bdist_egg"
69+
- <<: *eggs
70+
name: "python eggs 3.4"
71+
python: '3.4'
72+
73+
- <<: *eggs
74+
name: "python eggs 3.5"
75+
python: '3.5'
76+
77+
- <<: *eggs
78+
name: "python eggs 3.6"
79+
python: '3.6'
80+
81+
# - <<: *eggs
82+
# name: "python eggs 3.7"
83+
# python: '3.7'
84+
85+
cache:
86+
directories:
87+
- $HOME/.cache/pip
88+
- $HOME/.cache/pre-commit
89+
90+
install: pip install tox
91+
script:
92+
- python testing/runtests_travis.py

src/setuptools_scm/hg.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,9 @@ def parse(root, config=None):
5757
if tag == "null":
5858
tag = "0.0"
5959
dist = int(dist) + 1
60-
return _hg_tagdist_normalize_tagcommit(config.absolute_root, tag, dist, node, branch)
60+
return _hg_tagdist_normalize_tagcommit(
61+
config.absolute_root, tag, dist, node, branch
62+
)
6163
except ValueError:
6264
pass # unpacking failed, old hg
6365

src/setuptools_scm/version.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,7 @@ def tag_to_version(tag, config=None):
103103
if VERSION_CLASS is not None:
104104
version = pkg_parse_version(version)
105105
trace("version", repr(version))
106+
106107
return version
107108

108109

0 commit comments

Comments
 (0)