From 676f819c41e7e5c2a872a30ee36dfef8bb92caf1 Mon Sep 17 00:00:00 2001 From: Suchandra Thapa Date: Tue, 6 Apr 2021 07:29:21 -1000 Subject: [PATCH] Get version from environment --- setup.py | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/setup.py b/setup.py index 91a980d..93389f0 100644 --- a/setup.py +++ b/setup.py @@ -26,15 +26,24 @@ # OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE # OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. # setuptools loads some plugins necessary for use here. +import os + from setuptools import find_packages # noqa: F401 from distutils.core import setup + +version = os.getenv('servicex_version') +if version is None: + version = '0.1a1' +else: + version = version.split('/')[-1] + # Use the readme as the long description. with open("README.md", "r") as fh: long_description = fh.read() setup(name="servicex-cli", - version='1.0.0', + version=version, packages=find_packages('src'), package_dir={'': 'src'}, scripts=[],