You've already forked golang-saas-starter-kit
mirror of
https://github.com/raseels-repos/golang-saas-starter-kit.git
synced 2025-06-23 00:37:48 +02:00
fix git remote user
This commit is contained in:
@ -581,7 +581,6 @@ func gitRemoteUser(projectRoot string) string {
|
|||||||
if ev := os.Getenv("CI_PROJECT_PATH"); ev != "" {
|
if ev := os.Getenv("CI_PROJECT_PATH"); ev != "" {
|
||||||
if strings.Contains(ev, "/") {
|
if strings.Contains(ev, "/") {
|
||||||
remoteUrl = strings.Split(ev, "/")[1]
|
remoteUrl = strings.Split(ev, "/")[1]
|
||||||
remoteUrl = strings.Split(remoteUrl, "/")[0]
|
|
||||||
} else {
|
} else {
|
||||||
remoteUrl = ev
|
remoteUrl = ev
|
||||||
}
|
}
|
||||||
@ -599,7 +598,6 @@ func gitRemoteUser(projectRoot string) string {
|
|||||||
break
|
break
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if remoteUrl == "" {
|
if remoteUrl == "" {
|
||||||
return ""
|
return ""
|
||||||
@ -609,8 +607,11 @@ func gitRemoteUser(projectRoot string) string {
|
|||||||
if !strings.Contains(remoteUrl, ":") {
|
if !strings.Contains(remoteUrl, ":") {
|
||||||
return ""
|
return ""
|
||||||
}
|
}
|
||||||
remoteUser := strings.Split(remoteUrl, ":")[1]
|
remoteUrl = strings.Split(remoteUrl, ":")[1]
|
||||||
remoteUser = strings.Split(remoteUser, "/")[0]
|
|
||||||
|
}
|
||||||
|
|
||||||
|
remoteUser := strings.Split(remoteUrl, "/")[0]
|
||||||
|
|
||||||
return remoteUser
|
return remoteUser
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user