summaryrefslogtreecommitdiff
path: root/gitlab/config.py
diff options
context:
space:
mode:
authorKay-Uwe (Kiwi) Lorenz <kiwi@moduleworks.com>2021-03-07 15:51:46 +0100
committerKay-Uwe (Kiwi) Lorenz <kiwi@moduleworks.com>2021-03-07 15:51:46 +0100
commitfc7387a0a6039bc58b2a741ac9b73d7068375be7 (patch)
tree82fc9305f3c79e0651e049f5fffc272de3c807fb /gitlab/config.py
parentb5f43c83b25271f7aff917a9ce8826d39ff94034 (diff)
downloadgitlab-fc7387a0a6039bc58b2a741ac9b73d7068375be7.tar.gz
fix: let the homedir be expanded in path of helper
Diffstat (limited to 'gitlab/config.py')
-rw-r--r--gitlab/config.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/gitlab/config.py b/gitlab/config.py
index 09732bb..d2cdbfd 100644
--- a/gitlab/config.py
+++ b/gitlab/config.py
@@ -19,6 +19,7 @@ import os
import configparser
import subprocess
from typing import List, Optional, Union
+from os.path import expanduser
from gitlab.const import USER_AGENT
@@ -205,6 +206,6 @@ class GitlabConfigParser(object):
value = getattr(self, attr)
_value_lower = value.lower().strip()
if isinstance(value, str) and _value_lower.startswith(HELPER_PREFIX):
- helper = value[len(HELPER_PREFIX) :].strip()
+ helper = expanduser(value[len(HELPER_PREFIX) :].strip())
value = subprocess.check_output([helper]).decode("utf-8").strip()
setattr(self, attr, value) \ No newline at end of file