|
|
|
@ -63234,7 +63234,7 @@ function getGo(versionSpec, checkLatest, auth, arch = os_1.default.arch()) {
|
|
|
|
|
if (versionSpec === utils_1.StableReleaseAlias.Stable ||
|
|
|
|
|
versionSpec === utils_1.StableReleaseAlias.OldStable) {
|
|
|
|
|
manifest = yield getManifest(auth);
|
|
|
|
|
versionSpec = yield resolveStableVersionInput(versionSpec, auth, arch, manifest);
|
|
|
|
|
versionSpec = yield resolveStableVersionInput(versionSpec, arch, manifest);
|
|
|
|
|
}
|
|
|
|
|
if (checkLatest) {
|
|
|
|
|
core.info('Attempting to resolve the latest version from the manifest...');
|
|
|
|
@ -63405,7 +63405,7 @@ function findMatch(versionSpec, arch = os_1.default.arch()) {
|
|
|
|
|
const fixedCandidates = candidates.map(item => {
|
|
|
|
|
return Object.assign(Object.assign({}, item), { version: makeSemver(item.version) });
|
|
|
|
|
});
|
|
|
|
|
versionSpec = yield resolveStableVersionInput(versionSpec, undefined, archFilter, fixedCandidates);
|
|
|
|
|
versionSpec = yield resolveStableVersionInput(versionSpec, archFilter, fixedCandidates);
|
|
|
|
|
}
|
|
|
|
|
let goFile;
|
|
|
|
|
for (let i = 0; i < candidates.length; i++) {
|
|
|
|
@ -63479,13 +63479,9 @@ function parseGoVersionFile(versionFilePath) {
|
|
|
|
|
return contents.trim();
|
|
|
|
|
}
|
|
|
|
|
exports.parseGoVersionFile = parseGoVersionFile;
|
|
|
|
|
function resolveStableVersionInput(versionSpec, auth, arch = os_1.default.arch(), manifest) {
|
|
|
|
|
function resolveStableVersionInput(versionSpec, arch = os_1.default.arch(), manifest) {
|
|
|
|
|
var _a;
|
|
|
|
|
return __awaiter(this, void 0, void 0, function* () {
|
|
|
|
|
if (!manifest) {
|
|
|
|
|
core.debug('No manifest cached');
|
|
|
|
|
manifest = yield getManifest(auth);
|
|
|
|
|
}
|
|
|
|
|
const releases = manifest
|
|
|
|
|
.map(item => {
|
|
|
|
|
const index = item.files.findIndex(item => item.arch === arch);
|
|
|
|
|