Fix project name detection if we use https

This commit is contained in:
Denis Silakov 2018-10-21 11:10:32 +03:00
parent d66b4f1137
commit 87f2dc2b9b

View file

@ -45,7 +45,7 @@ def get_project_name(path=None):
e["LC_ALL"] = "C"
output, ret_code = execute_command(['git', 'remote', 'show', 'origin', '-n'], cwd=path, env=e)
m = re.compile("^.*Fetch URL:\s+.*abf.*:(.+)/([^/]+)[.]git$",re.MULTILINE).search(output)
m = re.compile("^.*Fetch URL:\s+.*abf.*[:/]([^/]+)/([^/]+)[.]git$",re.MULTILINE).search(output)
if m:
owner_name, project_name = m.groups()
return (owner_name, project_name)