1
0
mirror of https://github.com/christopherHX/gitea-download-artifact synced 2026-05-01 01:37:47 +02:00

v7 for gitea

This commit is contained in:
Christopher Homberger
2026-04-13 12:39:23 +02:00
parent 37930b1c2a
commit 89488ecb83

7
dist/index.js vendored
View File

@@ -2927,12 +2927,7 @@ function getResultsServiceUrl() {
return new URL(resultsUrl).origin;
}
function isGhes() {
const ghUrl = new URL(process.env['GITHUB_SERVER_URL'] || 'https://github.com');
const hostname = ghUrl.hostname.trimEnd().toUpperCase();
const isGitHubHost = hostname === 'GITHUB.COM';
const isGheHost = hostname.endsWith('.GHE.COM');
const isLocalHost = hostname.endsWith('.LOCALHOST');
return !isGitHubHost && !isGheHost && !isLocalHost;
return false;
}
function getGitHubWorkspaceDir() {
const ghWorkspaceDir = process.env['GITHUB_WORKSPACE'];