Skip to content

Commit 41dbb76

Browse files
author
Cosimo Lupo
committed
.travis.yml: git fetch --unshallow to retrieve the full git metadata to generate version string with setuptools_scm
1 parent 54d9831 commit 41dbb76

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

.travis.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,11 @@ python:
77
install:
88
- pip install --upgrade pip setuptools wheel
99
- pip install tox-travis
10+
# Travis by default only clones a 'shallow' repository with --depth=50.
11+
# When building the distribution packages, we use git to determine the
12+
# package version string (via setuptools_scm), hence we need to fetch
13+
# the whole repo, and not just the last 50 commits.
14+
- if [[ $TRAVIS_PYTHON_VERSION == 3.5 ]]; then git fetch --unshallow; fi
1015
script: tox
1116
after_success:
1217
- pip wheel --no-deps -w dist .

0 commit comments

Comments
 (0)