From 00fec2558685ea4c13a8ed0d732995b86e470847 Mon Sep 17 00:00:00 2001 From: Miguel Angel Garcia Date: Sun, 28 Feb 2021 19:51:54 +0100 Subject: [PATCH] fix version --- setup.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/setup.py b/setup.py index 6960617..e63b3b1 100644 --- a/setup.py +++ b/setup.py @@ -1,5 +1,6 @@ # -*- coding: utf-8 -*- +import os import sys from io import open @@ -7,6 +8,9 @@ from setuptools.command.test import test as TestCommand version = "2.0.1" +github_ref = os.getenv("GITHUB_REF") +if github_ref and github_ref.startswith("refs/tags"): + version = github_ref[10:] def read_description():