switch GITHUB_URL to GITHUB_SERVER_URL (#248)

pull/251/head
eric sciple 5 years ago committed by GitHub
parent ac455590d1
commit 7523e23789
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

5
dist/index.js vendored

@ -1400,7 +1400,10 @@ function getFetchUrl(settings) {
}
exports.getFetchUrl = getFetchUrl;
function getServerUrl() {
return new url_1.URL(process.env['GITHUB_URL'] || 'https://github.com');
// todo: remove GITHUB_URL after support for GHES Alpha is no longer needed
return new url_1.URL(process.env['GITHUB_SERVER_URL'] ||
process.env['GITHUB_URL'] ||
'https://github.com');
}
exports.getServerUrl = getServerUrl;

@ -20,5 +20,10 @@ export function getFetchUrl(settings: IGitSourceSettings): string {
}
export function getServerUrl(): URL {
return new URL(process.env['GITHUB_URL'] || 'https://github.com')
// todo: remove GITHUB_URL after support for GHES Alpha is no longer needed
return new URL(
process.env['GITHUB_SERVER_URL'] ||
process.env['GITHUB_URL'] ||
'https://github.com'
)
}

Loading…
Cancel
Save