Fix logical error

This commit is contained in:
Joseph Garrone
2024-05-19 04:44:38 +02:00
parent 10da0cab47
commit ac414489ff

View File

@ -18,19 +18,19 @@ export async function command(params: { cliCommandOptions: CliCommandOptions })
commandOutput = child_process.execSync("mvn --version", { "stdio": ["ignore", "pipe", "ignore"] }); commandOutput = child_process.execSync("mvn --version", { "stdio": ["ignore", "pipe", "ignore"] });
} catch {} } catch {}
if (!commandOutput?.toString("utf8").includes("Apache Maven")) { if (commandOutput?.toString("utf8").includes("Apache Maven")) {
break exit_if_maven_not_installed; break exit_if_maven_not_installed;
} }
const installationCommand = (() => { const installationCommand = (() => {
switch (os.platform()) { switch (os.platform()) {
case "darwin": case "darwin":
return "brew install nvm"; return "brew install mvn";
case "win32": case "win32":
return "choco install nvm"; return "choco install mvn";
case "linux": case "linux":
default: default:
return "sudo apt-get install nvm"; return "sudo apt-get install mvn";
} }
})(); })();