blob: cd41b089cf5009f8272a79914b42bc139be73669 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
|
const VERSION = "v1.37.11";
const exitNotSupported = () => {
console.error(chalk.red(`${os.platform()} ${os.arch()} is currently not supported.`));
process.exit(1);
};
export const getDownloadUrl = () => {
const target = (() => {
switch (os.platform()) {
case "darwin":
return "omnisharp-osx.zip";
case "win32":
switch (os.arch()) {
case "arm64":
return "omnisharp-win-arm64.zip";
case "x64":
return "omnisharp-win-x64.zip";
default:
return exitNotSupported();
}
default:
switch (os.arch()) {
case "arm64":
return exitNotSupported();
case "x64":
return "omnisharp-linux-x64.zip";
default:
return exitNotSupported();
}
}
})();
return `https://github.com/OmniSharp/omnisharp-roslyn/releases/download/${VERSION}/${target}`;
};
|