xvcxyvxcyv
This commit is contained in:
8
dist/index.js
vendored
8
dist/index.js
vendored
@@ -36005,7 +36005,7 @@ function getFetchUrl(settings) {
|
|||||||
const encodedOwner = encodeURIComponent(settings.repositoryOwner);
|
const encodedOwner = encodeURIComponent(settings.repositoryOwner);
|
||||||
const encodedName = encodeURIComponent(settings.repositoryName);
|
const encodedName = encodeURIComponent(settings.repositoryName);
|
||||||
if (settings.sshKey) {
|
if (settings.sshKey) {
|
||||||
return `git@${serviceUrl.hostname}/gitea:${encodedOwner}/${encodedName}.git`;
|
return `git@${serviceUrl.hostname}:${encodedOwner}/${encodedName}.git`;
|
||||||
}
|
}
|
||||||
// "origin" is SCHEME://HOSTNAME[:PORT]
|
// "origin" is SCHEME://HOSTNAME[:PORT]
|
||||||
return `${serviceUrl.origin}/${encodedOwner}/${encodedName}`;
|
return `${serviceUrl.origin}/${encodedOwner}/${encodedName}`;
|
||||||
@@ -36013,9 +36013,9 @@ function getFetchUrl(settings) {
|
|||||||
exports.getFetchUrl = getFetchUrl;
|
exports.getFetchUrl = getFetchUrl;
|
||||||
function getServerUrl() {
|
function getServerUrl() {
|
||||||
// todo: remove GITHUB_URL after support for GHES Alpha is no longer needed
|
// todo: remove GITHUB_URL after support for GHES Alpha is no longer needed
|
||||||
return new url_1.URL(process.env['GITHUB_SERVER_URL'] ||
|
return new url_1.URL(process.env['GITHUB_SERVER_URL'] + '/gitea' ||
|
||||||
process.env['GITHUB_URL'] ||
|
0 ||
|
||||||
'https://github.com');
|
0);
|
||||||
}
|
}
|
||||||
exports.getServerUrl = getServerUrl;
|
exports.getServerUrl = getServerUrl;
|
||||||
|
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ export function getFetchUrl(settings: IGitSourceSettings): string {
|
|||||||
const encodedOwner = encodeURIComponent(settings.repositoryOwner)
|
const encodedOwner = encodeURIComponent(settings.repositoryOwner)
|
||||||
const encodedName = encodeURIComponent(settings.repositoryName)
|
const encodedName = encodeURIComponent(settings.repositoryName)
|
||||||
if (settings.sshKey) {
|
if (settings.sshKey) {
|
||||||
return `git@${serviceUrl.hostname}/gitea:${encodedOwner}/${encodedName}.git`
|
return `git@${serviceUrl.hostname}:${encodedOwner}/${encodedName}.git`
|
||||||
}
|
}
|
||||||
|
|
||||||
// "origin" is SCHEME://HOSTNAME[:PORT]
|
// "origin" is SCHEME://HOSTNAME[:PORT]
|
||||||
@@ -22,7 +22,7 @@ export function getFetchUrl(settings: IGitSourceSettings): string {
|
|||||||
export function getServerUrl(): URL {
|
export function getServerUrl(): URL {
|
||||||
// todo: remove GITHUB_URL after support for GHES Alpha is no longer needed
|
// todo: remove GITHUB_URL after support for GHES Alpha is no longer needed
|
||||||
return new URL(
|
return new URL(
|
||||||
process.env['GITHUB_SERVER_URL'] ||
|
process.env['GITHUB_SERVER_URL'] + '/gitea' ||
|
||||||
process.env['GITHUB_URL'] ||
|
process.env['GITHUB_URL'] ||
|
||||||
'https://github.com'
|
'https://github.com'
|
||||||
)
|
)
|
||||||
|
|||||||
Reference in New Issue
Block a user