|
|
|
@ -77034,6 +77034,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
|
|
Object.defineProperty(exports, "__esModule", ({ value: true }));
|
|
|
|
exports.GOTOOLCHAIN_LOCAL_VAL = exports.GOTOOLCHAIN_ENV_VAR = void 0;
|
|
|
|
exports.GOTOOLCHAIN_LOCAL_VAL = exports.GOTOOLCHAIN_ENV_VAR = void 0;
|
|
|
|
exports.getGo = getGo;
|
|
|
|
exports.getGo = getGo;
|
|
|
|
|
|
|
|
exports.customToolCacheName = customToolCacheName;
|
|
|
|
exports.extractGoArchive = extractGoArchive;
|
|
|
|
exports.extractGoArchive = extractGoArchive;
|
|
|
|
exports.getManifest = getManifest;
|
|
|
|
exports.getManifest = getManifest;
|
|
|
|
exports.getInfoFromManifest = getInfoFromManifest;
|
|
|
|
exports.getInfoFromManifest = getInfoFromManifest;
|
|
|
|
@ -77049,6 +77050,7 @@ const path = __importStar(__nccwpck_require__(16928));
|
|
|
|
const semver = __importStar(__nccwpck_require__(62088));
|
|
|
|
const semver = __importStar(__nccwpck_require__(62088));
|
|
|
|
const httpm = __importStar(__nccwpck_require__(54844));
|
|
|
|
const httpm = __importStar(__nccwpck_require__(54844));
|
|
|
|
const sys = __importStar(__nccwpck_require__(57666));
|
|
|
|
const sys = __importStar(__nccwpck_require__(57666));
|
|
|
|
|
|
|
|
const crypto_1 = __importDefault(__nccwpck_require__(76982));
|
|
|
|
const child_process_1 = __importDefault(__nccwpck_require__(35317));
|
|
|
|
const child_process_1 = __importDefault(__nccwpck_require__(35317));
|
|
|
|
const fs_1 = __importDefault(__nccwpck_require__(79896));
|
|
|
|
const fs_1 = __importDefault(__nccwpck_require__(79896));
|
|
|
|
const os_1 = __importDefault(__nccwpck_require__(70857));
|
|
|
|
const os_1 = __importDefault(__nccwpck_require__(70857));
|
|
|
|
@ -77101,7 +77103,9 @@ function getGo(versionSpec_1, checkLatest_1, auth_1) {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// Use a distinct tool cache name for custom downloads to avoid
|
|
|
|
// Use a distinct tool cache name for custom downloads to avoid
|
|
|
|
// colliding with the runner's pre-installed Go
|
|
|
|
// colliding with the runner's pre-installed Go
|
|
|
|
const toolCacheName = customBaseUrl ? 'go-custom' : 'go';
|
|
|
|
const toolCacheName = customBaseUrl
|
|
|
|
|
|
|
|
? customToolCacheName(customBaseUrl)
|
|
|
|
|
|
|
|
: 'go';
|
|
|
|
// check cache
|
|
|
|
// check cache
|
|
|
|
const toolPath = tc.find(toolCacheName, versionSpec, arch);
|
|
|
|
const toolPath = tc.find(toolCacheName, versionSpec, arch);
|
|
|
|
// If not found in cache, download
|
|
|
|
// If not found in cache, download
|
|
|
|
@ -77237,6 +77241,10 @@ function addExecutablesToToolCache(extPath_1, info_1, arch_1) {
|
|
|
|
(yield tc.cacheDir(extPath, toolName, version, arch)));
|
|
|
|
(yield tc.cacheDir(extPath, toolName, version, arch)));
|
|
|
|
});
|
|
|
|
});
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
function customToolCacheName(baseUrl) {
|
|
|
|
|
|
|
|
const hash = crypto_1.default.createHash('sha256').update(baseUrl).digest('hex');
|
|
|
|
|
|
|
|
return `go-${hash.substring(0, 8)}`;
|
|
|
|
|
|
|
|
}
|
|
|
|
function installGoVersion(info_1, auth_1, arch_1) {
|
|
|
|
function installGoVersion(info_1, auth_1, arch_1) {
|
|
|
|
return __awaiter(this, arguments, void 0, function* (info, auth, arch, toolName = 'go') {
|
|
|
|
return __awaiter(this, arguments, void 0, function* (info, auth, arch, toolName = 'go') {
|
|
|
|
core.info(`Acquiring ${info.resolvedVersion} from ${info.downloadUrl}`);
|
|
|
|
core.info(`Acquiring ${info.resolvedVersion} from ${info.downloadUrl}`);
|
|
|
|
|