From e218542141fdda3a780d82e2e363d38e12a465bb Mon Sep 17 00:00:00 2001 From: Veikka Tuominen Date: Tue, 26 Mar 2024 10:48:36 +0200 Subject: [PATCH] fix installing zig when no project is open This whole execCmd stuff is borrowed from somewhere else and should probably be removed. Closes #125 --- src/zigUtil.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/zigUtil.ts b/src/zigUtil.ts index de77574..e75070e 100644 --- a/src/zigUtil.ts +++ b/src/zigUtil.ts @@ -54,7 +54,7 @@ export function execCmd const cmdArguments = options ? options.cmdArguments : []; childProcess = - cp.execFile(cmd, cmdArguments, { cwd: detectProjectRoot(fileName || workspace.rootPath + "/fakeFileName"), maxBuffer: 10 * 1024 * 1024 }, handleExit); + cp.execFile(cmd, cmdArguments, { cwd: detectProjectRoot(fileName || ""), maxBuffer: 10 * 1024 * 1024 }, handleExit); childProcess.stdout.on("data", (data: Buffer) => {