MCPcopy Create free account
hub / github.com/OpenHands/OpenHands / commandExists

Function commandExists

scripts/dev-with-automation.mjs:618–625  ·  view source on GitHub ↗
(cmd)

Source from the content-addressed store, hash-verified

616// ═══════════════════════════════════════════════════════════════════════════
617
618function commandExists(cmd) {
619 const result =
620 process.platform === "win32"
621 ? spawnSync("where.exe", [cmd], { stdio: "pipe" })
622 : spawnSync("sh", ["-c", `command -v ${cmd}`], { stdio: "pipe" });
623
624 return result.status === 0;
625}
626
627function checkPrerequisites({
628 checkUvx = true,

Callers 1

checkPrerequisitesFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected