From 88d5fe677e93f4fe05c30403a90c9c61fb7d746f Mon Sep 17 00:00:00 2001 From: haasad Date: Sat, 19 Feb 2022 08:26:36 +0100 Subject: [PATCH 1/2] Get version from git tag env variable used during build --- conda-recipe/meta.yaml | 7 ++----- setup.py | 3 ++- 2 files changed, 4 insertions(+), 6 deletions(-) diff --git a/conda-recipe/meta.yaml b/conda-recipe/meta.yaml index bd80d3b..16b3add 100644 --- a/conda-recipe/meta.yaml +++ b/conda-recipe/meta.yaml @@ -1,9 +1,6 @@ -{% set name = "eidl" %} -{% set version = "1.4.0" %} - package: - name: {{ name|lower }} - version: {{ version }} + name: eidl + version: "{{ GIT_DESCRIBE_TAG }}" source: path: .. diff --git a/setup.py b/setup.py index 65ed120..b8bb11b 100644 --- a/setup.py +++ b/setup.py @@ -1,9 +1,10 @@ +import os from setuptools import setup setup( name='eidl', packages=['eidl'], - version='1.4.0', + version=os.environ.get('GIT_DESCRIBE_TAG', '0.0.0'), author="Adrian Haas", url="https://github.com/haasad/EcoInventDownLoader", license=open('LICENSE').read(), From 1b4919bcc3d5486bdd64bf1446f60c09ae7eb806 Mon Sep 17 00:00:00 2001 From: haasad Date: Sat, 19 Feb 2022 10:32:58 +0100 Subject: [PATCH 2/2] Build from github repo --- conda-recipe/meta.yaml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/conda-recipe/meta.yaml b/conda-recipe/meta.yaml index 16b3add..4ddfb2a 100644 --- a/conda-recipe/meta.yaml +++ b/conda-recipe/meta.yaml @@ -3,7 +3,8 @@ package: version: "{{ GIT_DESCRIBE_TAG }}" source: - path: .. + git_url: https://github.com/haasad/EcoInventDownLoader.git + git_rev: master build: noarch: python @@ -27,7 +28,7 @@ requirements: test: imports: - - {{ name }} + - eidl about: home: https://github.com/haasad/EcoInventDownLoader