mirror of
https://gitea.com/actions/setup-deno.git
synced 2025-12-11 19:06:43 +00:00
Compare commits
2 Commits
v1
...
v1-depreca
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
70768ed567 | ||
|
|
5f06e8aafb |
4
main.mjs
4
main.mjs
@@ -17,6 +17,10 @@ function exit(message) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
async function main() {
|
async function main() {
|
||||||
|
core.warning(
|
||||||
|
"Running on setup-deno@1, which is deprecated.\nPlease update to setup-deno@2, which defaults to Deno 2.0",
|
||||||
|
);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const denoVersionFile = core.getInput("deno-version-file");
|
const denoVersionFile = core.getInput("deno-version-file");
|
||||||
const range = parseVersionRange(
|
const range = parseVersionRange(
|
||||||
|
|||||||
@@ -20,20 +20,9 @@ export async function install(version) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const zip = zipName();
|
const zip = zipName();
|
||||||
let url;
|
const url = version.kind === "canary"
|
||||||
|
? `https://dl.deno.land/canary/${version.version}/${zip}`
|
||||||
switch (version.kind) {
|
: `https://dl.deno.land/release/v${version.version}/${zip}`;
|
||||||
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