File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -1064,8 +1064,14 @@ def getProject(filename):
10641064 proj = None
10651065 for remote in localRepo .remotes :
10661066 for url in remote .urls :
1067- if "gitlab.pavlovia.org/" in url :
1068- namespaceName = url .split ('gitlab.pavlovia.org/' )[1 ]
1067+ if "gitlab.pavlovia.org" in url :
1068+ # could be 'https://gitlab.pavlovia.org/NameSpace/Name.git'
1069+ # or may be 'git@gitlab.pavlovia.org:NameSpace/Name.git'
1070+ namespaceName = url .split ('gitlab.pavlovia.org' )[1 ]
1071+ # remove the first char (: or /)
1072+ if namespaceName [0 ] in ['/' , ':' ]:
1073+ namespaceName = namespaceName [1 :]
1074+ # remove the .git at the end if present
10691075 namespaceName = namespaceName .replace ('.git' , '' )
10701076 pavSession = getCurrentSession ()
10711077 if not pavSession .user :
You can’t perform that action at this time.
0 commit comments