From f2690939c6f2d358ffe1de56c8f60e591ab829a2 Mon Sep 17 00:00:00 2001 From: Uilian Ries Date: Thu, 1 Jun 2023 12:06:24 +0200 Subject: [PATCH] support new gitlab variable Signed-off-by: Uilian Ries --- cpt/__init__.py | 2 +- cpt/ci_manager.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/cpt/__init__.py b/cpt/__init__.py index 084c581b..5ef40bf5 100644 --- a/cpt/__init__.py +++ b/cpt/__init__.py @@ -1,5 +1,5 @@ -__version__ = '0.39.0' +__version__ = '0.39.1' def get_client_version(): diff --git a/cpt/ci_manager.py b/cpt/ci_manager.py index f1d76bf4..3b190d14 100644 --- a/cpt/ci_manager.py +++ b/cpt/ci_manager.py @@ -244,7 +244,7 @@ def get_commit_id(self): return os.getenv("CI_COMMIT_SHA", None) def get_branch(self): - return os.getenv("CI_BUILD_REF_NAME", None) + return os.getenv("CI_BUILD_REF_NAME", None) or os.getenv("CI_COMMIT_REF_NAME", None) def is_pull_request(self): return os.getenv("CI_MERGE_REQUEST_ID", None)