MCPcopy Create free account
hub / github.com/NativeScript/SimDeck / readVersion

Function readVersion

scripts/bench/agent-control-benchmark.mjs:1106–1112  ·  view source on GitHub ↗
(command, args)

Source from the content-addressed store, hash-verified

1104}
1105
1106function readVersion(command, args) {
1107 const result = run(command, args, { timeoutMs: 5000, allowFailure: true });
1108 return (result.stdout || result.stderr || "unavailable")
1109 .trim()
1110 .split(/\s+/)
1111 .pop();
1112}
1113
1114function globalPackageRoot(packageName) {
1115 const result = run("npm", ["root", "-g"], { timeoutMs: 10000 });

Callers 1

mainFunction · 0.85

Calls 1

runFunction · 0.70

Tested by

no test coverage detected