sdfsdf xcvxcvxcv

This commit is contained in:
Michael Schmidt
2023-07-10 15:42:21 +02:00
parent be5e352fa7
commit bdc764ff89
3 changed files with 6 additions and 6 deletions

View File

@@ -53,7 +53,7 @@ class GitAuthHelper {
// Token auth header
const serverUrl = urlHelper.getServerUrl()
this.tokenConfigKey = `http.${serverUrl.origin}/.extraheader` // "origin" is SCHEME://HOSTNAME[:PORT]
this.tokenConfigKey = `http.${serverUrl.origin}${serverUrl.pathname}/.extraheader` // "origin" is SCHEME://HOSTNAME[:PORT]
const basicCredential = Buffer.from(
`x-access-token:${this.settings.authToken}`,
'utf8'
@@ -63,7 +63,7 @@ class GitAuthHelper {
this.tokenConfigValue = `AUTHORIZATION: basic ${basicCredential}`
// Instead of SSH URL
this.insteadOfKey = `url.${serverUrl.origin}/.insteadOf` // "origin" is SCHEME://HOSTNAME[:PORT]
this.insteadOfKey = `url.${serverUrl.origin}${serverUrl.pathname}/.insteadOf` // "origin" is SCHEME://HOSTNAME[:PORT]
this.insteadOfValues.push(`git@${serverUrl.hostname}:`)
if (this.settings.workflowOrganizationId) {
this.insteadOfValues.push(

View File

@@ -16,7 +16,7 @@ export function getFetchUrl(settings: IGitSourceSettings): string {
}
// "origin" is SCHEME://HOSTNAME[:PORT]
return `${serviceUrl.origin}${serviceUrl.pathname}${encodedOwner}/${encodedName}`
return `${serviceUrl.origin}${serviceUrl.pathname}/${encodedOwner}/${encodedName}`
}
export function getServerUrl(): URL {