mirror of
https://gitea.com/actions/setup-deno.git
synced 2025-12-12 11:27:10 +00:00
refactor: use GitHub downloads for stable version download (#91)
This commit is contained in:
@@ -20,9 +20,20 @@ export async function install(version) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const zip = zipName();
|
const zip = zipName();
|
||||||
const url = version.kind === "canary"
|
let url;
|
||||||
? `https://dl.deno.land/canary/${version.version}/${zip}`
|
|
||||||
: `https://dl.deno.land/release/v${version.version}/${zip}`;
|
switch (version.kind) {
|
||||||
|
case "canary":
|
||||||
|
url = `https://dl.deno.land/canary/${version.version}/${zip}`;
|
||||||
|
break;
|
||||||
|
case "rc":
|
||||||
|
url = `https://dl.deno.land/release/v${version.version}/${zip}`;
|
||||||
|
break;
|
||||||
|
case "stable":
|
||||||
|
url =
|
||||||
|
`https://github.com/denoland/deno/releases/download/v${version.version}/${zip}`;
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
|
||||||
core.info(`Downloading Deno from ${url}.`);
|
core.info(`Downloading Deno from ${url}.`);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user