From bce7996a9543125bad28b41e4854bc5bae727cdb Mon Sep 17 00:00:00 2001 From: Gar Date: Wed, 3 Aug 2022 09:50:13 -0700 Subject: [PATCH] fix: only try to run global bin if the bin name exists subdeps are in the tree but they don't have a bin --- workspaces/libnpmexec/lib/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/workspaces/libnpmexec/lib/index.js b/workspaces/libnpmexec/lib/index.js index efaeccafb615b..0b0565ca92072 100644 --- a/workspaces/libnpmexec/lib/index.js +++ b/workspaces/libnpmexec/lib/index.js @@ -161,7 +161,7 @@ const exec = async (opts) => { const globalTree = await globalArb.loadActual() const { manifest: globalManifest } = await missingFromTree({ spec, tree: globalTree, flatOptions }) - if (!globalManifest) { + if (!globalManifest && await fileExists(`${globalBin}/${args[0]}`)) { binPaths.push(globalBin) return await run() }