From b07e2f299907989671c63bb5ee100bdc13f45eb5 Mon Sep 17 00:00:00 2001 From: Nate Sesti Date: Mon, 14 Aug 2023 17:52:28 -0700 Subject: set permissions to /exe --- extension/src/activation/environmentSetup.ts | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) (limited to 'extension/src') diff --git a/extension/src/activation/environmentSetup.ts b/extension/src/activation/environmentSetup.ts index c87f1a7b..3cb702ac 100644 --- a/extension/src/activation/environmentSetup.ts +++ b/extension/src/activation/environmentSetup.ts @@ -203,17 +203,18 @@ export async function startContinuePythonServer(redownload: boolean = true) { } ); console.log("Downloaded server executable at ", destination); - // Get name of the corresponding executable for platform - if (os.platform() === "darwin") { - // Add necessary permissions - fs.chmodSync(destination, 0o7_5_5); - await runCommand(`xattr -dr com.apple.quarantine ${destination}`); - } else if (os.platform() === "linux") { - // Add necessary permissions - fs.chmodSync(destination, 0o7_5_5); - } } - + + // Get name of the corresponding executable for platform + if (os.platform() === "darwin") { + // Add necessary permissions + fs.chmodSync(destination, 0o7_5_5); + await runCommand(`xattr -dr com.apple.quarantine ${destination}`); + } else if (os.platform() === "linux") { + // Add necessary permissions + fs.chmodSync(destination, 0o7_5_5); + } + // Validate that the file exists console.log("Looking for file at ", destination); if (!fs.existsSync(destination)) { -- cgit v1.2.3-70-g09d2