aboutsummaryrefslogtreecommitdiff
path: root/editors/code/src/installation
diff options
context:
space:
mode:
Diffstat (limited to 'editors/code/src/installation')
-rw-r--r--editors/code/src/installation/language_server.ts10
1 files changed, 3 insertions, 7 deletions
diff --git a/editors/code/src/installation/language_server.ts b/editors/code/src/installation/language_server.ts
index e571cbc98..a169eae47 100644
--- a/editors/code/src/installation/language_server.ts
+++ b/editors/code/src/installation/language_server.ts
@@ -1,4 +1,3 @@
1import { unwrapNotNil } from "ts-not-nil";
2import { spawnSync } from "child_process"; 1import { spawnSync } from "child_process";
3import * as vscode from "vscode"; 2import * as vscode from "vscode";
4import * as path from "path"; 3import * as path from "path";
@@ -12,12 +11,9 @@ import { downloadFile } from "./download_file";
12export async function downloadLatestLanguageServer( 11export async function downloadLatestLanguageServer(
13 {file: artifactFileName, dir: installationDir, repo}: BinarySource.GithubRelease 12 {file: artifactFileName, dir: installationDir, repo}: BinarySource.GithubRelease
14) { 13) {
15 const binaryMetadata = await fetchLatestArtifactMetadata(repo, artifactFileName); 14 const { releaseName, downloadUrl } = (await fetchLatestArtifactMetadata(
16 15 repo, artifactFileName
17 const { 16 ))!;
18 releaseName,
19 downloadUrl
20 } = unwrapNotNil(binaryMetadata, `Latest GitHub release lacks "${artifactFileName}" file`);
21 17
22 await fs.mkdir(installationDir).catch(err => assert.strictEqual( 18 await fs.mkdir(installationDir).catch(err => assert.strictEqual(
23 err?.code, 19 err?.code,