File tree Expand file tree Collapse file tree 2 files changed +2
-23
lines changed
Expand file tree Collapse file tree 2 files changed +2
-23
lines changed Original file line number Diff line number Diff line change @@ -23,6 +23,7 @@ install:
2323script :
2424- flake8 connect
2525- pytest --cov-report=xml --cov=./connect
26+ - sed -i "s/version='0.0.0'/version='${TRAVIS_TAG}'/g" setup.py
2627
2728after_success :
2829- bash <(curl -s https://codecov.io/bash)
Original file line number Diff line number Diff line change 77"""
88
99from os .path import abspath , dirname , exists , join
10- from os import environ
1110from setuptools import find_packages , setup
12- from warnings import warn
1311
1412try : # for pip >= 10
1513 # noinspection PyProtectedMember,PyPackageRequirements
2624 'sdk.txt' ,
2725 ), session = 'None' )
2826
29- # Get path to version file
30- version_path = join (
31- dirname (abspath (__file__ )),
32- 'VERSION'
33- )
34-
35- # Try to write version file from Travis tag
36- travis_tag = environ .get ('TRAVIS_TAG' )
37- if travis_tag and travis_tag .strip ():
38- with open (version_path , 'w' ) as version_file :
39- version_file .write (travis_tag .strip ())
40-
41- # Try to read version from file
42- try :
43- with open (version_path , 'r' ) as version_file :
44- VERSION = version_file .read ().strip ()
45- except IOError :
46- warn ('`{}` file could not be read.' .format (version_path ), RuntimeWarning )
47- VERSION = ''
48-
4927PACKAGES = find_packages (exclude = ['tests*' ])
5028
5129DOC = ''
5533setup (
5634 name = 'connect-sdk' ,
5735 author = 'Ingram Micro' ,
58- version = VERSION ,
36+ version = '0.0.0' ,
5937 keywords = 'sdk connect connect automation' ,
6038 packages = PACKAGES ,
6139 description = 'Connect Python SDK' ,
You can’t perform that action at this time.
0 commit comments