aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-01-04 14:57:18 +0000
committerGitHub <[email protected]>2021-01-04 14:57:18 +0000
commitcb10a53b16205de828fcc564a1dde2ad0b2cbde5 (patch)
tree7162d2a94df3cfad94fa5010d4b448c733858e96
parent484df745cc4885a5f05ce7a5d5d1be4215bcb5d3 (diff)
parent9decc4c0a395df7a77c6a2c3841d3a7876c0a1a6 (diff)
Merge #7151
7151: Allow download of aarch64-pc-windows-msvc binaries r=matklad a=lnicola Co-authored-by: LaurenČ›iu Nicola <[email protected]>
-rw-r--r--editors/code/src/main.ts19
1 files changed, 9 insertions, 10 deletions
diff --git a/editors/code/src/main.ts b/editors/code/src/main.ts
index 60907dfd4..4c132cabe 100644
--- a/editors/code/src/main.ts
+++ b/editors/code/src/main.ts
@@ -287,16 +287,15 @@ async function getServer(config: Config, state: PersistentState): Promise<string
287 }; 287 };
288 if (config.package.releaseTag === null) return "rust-analyzer"; 288 if (config.package.releaseTag === null) return "rust-analyzer";
289 289
290 let platform: string | undefined; 290 const platforms: { [key: string]: string } = {
291 if ((process.arch === "x64" || process.arch === "ia32") && process.platform === "win32") { 291 "ia32 win32": "x86_64-pc-windows-msvc",
292 platform = "x86_64-pc-windows-msvc"; 292 "x64 win32": "x86_64-pc-windows-msvc",
293 } else if (process.arch === "x64" && process.platform === "linux") { 293 "x64 linux": "x86_64-unknown-linux-gnu",
294 platform = "x86_64-unknown-linux-gnu"; 294 "x64 darwin": "x86_64-apple-darwin",
295 } else if (process.arch === "x64" && process.platform === "darwin") { 295 "arm64 win32": "aarch64-pc-windows-msvc",
296 platform = "x86_64-apple-darwin"; 296 "arm64 darwin": "aarch64-apple-darwin",
297 } else if (process.arch === "arm64" && process.platform === "darwin") { 297 };
298 platform = "aarch64-apple-darwin"; 298 const platform = platforms[`${process.arch} ${process.platform}`];
299 }
300 if (platform === undefined) { 299 if (platform === undefined) {
301 vscode.window.showErrorMessage( 300 vscode.window.showErrorMessage(
302 "Unfortunately we don't ship binaries for your platform yet. " + 301 "Unfortunately we don't ship binaries for your platform yet. " +