0
1
Fork 0

Compare commits

...

3 Commits

Author SHA1 Message Date
Masahiro Furudate d788481461
Merge e07c5f5f0b into be1aa1186e 2024-04-13 14:46:56 +00:00
Masahiro Furudate e07c5f5f0b Run `npm run build` 2024-04-13 23:46:49 +09:00
Masahiro Furudate 764529a2a0 Fix const name 2024-04-13 23:44:39 +09:00
2 changed files with 6 additions and 7 deletions

7
dist/setup/index.js vendored
View File

@ -88039,6 +88039,7 @@ const sys = __importStar(__nccwpck_require__(5632));
const fs_1 = __importDefault(__nccwpck_require__(7147));
const os_1 = __importDefault(__nccwpck_require__(2037));
const utils_1 = __nccwpck_require__(1314);
const GOLANG_DOWNLOAD_URL = 'https://go.dev/dl/?mode=json&include=all';
function getGo(versionSpec_1, checkLatest_1, auth_1) {
return __awaiter(this, arguments, void 0, function* (versionSpec, checkLatest, auth, arch = os_1.default.arch()) {
var _a;
@ -88258,8 +88259,7 @@ function findMatch(versionSpec_1) {
const platFilter = sys.getPlatform();
let result;
let match;
const dlUrl = 'https://golang.org/dl/?mode=json&include=all';
const candidates = yield module.exports.getVersionsDist(dlUrl);
const candidates = yield module.exports.getVersionsDist(GOLANG_DOWNLOAD_URL);
if (!candidates) {
throw new Error(`golang download url did not return results`);
}
@ -88339,8 +88339,7 @@ function resolveStableVersionDist(versionSpec, arch) {
return __awaiter(this, void 0, void 0, function* () {
const archFilter = sys.getArch(arch);
const platFilter = sys.getPlatform();
const dlUrl = 'https://golang.org/dl/?mode=json&include=all';
const candidates = yield module.exports.getVersionsDist(dlUrl);
const candidates = yield module.exports.getVersionsDist(GOLANG_DOWNLOAD_URL);
if (!candidates) {
throw new Error(`golang download url did not return results`);
}

View File

@ -10,7 +10,7 @@ import {StableReleaseAlias} from './utils';
type InstallationType = 'dist' | 'manifest';
const golangDownloadUrl = 'https://go.dev/dl/?mode=json&include=all';
const GOLANG_DOWNLOAD_URL = 'https://go.dev/dl/?mode=json&include=all';
export interface IGoVersionFile {
filename: string;
@ -338,7 +338,7 @@ export async function findMatch(
let match: IGoVersion | undefined;
const candidates: IGoVersion[] | null = await module.exports.getVersionsDist(
golangDownloadUrl
GOLANG_DOWNLOAD_URL
);
if (!candidates) {
throw new Error(`golang download url did not return results`);
@ -436,7 +436,7 @@ async function resolveStableVersionDist(versionSpec: string, arch: string) {
const archFilter = sys.getArch(arch);
const platFilter = sys.getPlatform();
const candidates: IGoVersion[] | null = await module.exports.getVersionsDist(
golangDownloadUrl
GOLANG_DOWNLOAD_URL
);
if (!candidates) {
throw new Error(`golang download url did not return results`);