fix(mac): run remote health with pnpm under zsh
This commit is contained in:
@@ -349,13 +349,15 @@ enum CommandResolver {
|
|||||||
let scriptBody = """
|
let scriptBody = """
|
||||||
PATH=\(exportedPath);
|
PATH=\(exportedPath);
|
||||||
\(prjVar)
|
\(prjVar)
|
||||||
CLI="";
|
if command -v clawdis >/dev/null 2>&1; then
|
||||||
if command -v clawdis >/dev/null 2>&1; then CLI="clawdis";
|
\(cdPrefix)clawdis \(quotedArgs);
|
||||||
elif [ -n "${PRJ:-}" ] && [ -f "$PRJ/bin/clawdis.js" ] && command -v node >/dev/null 2>&1; then CLI="node $PRJ/bin/clawdis.js";
|
elif [ -n "${PRJ:-}" ] && [ -f "$PRJ/bin/clawdis.js" ] && command -v node >/dev/null 2>&1; then
|
||||||
elif command -v pnpm >/dev/null 2>&1; then CLI="pnpm --silent clawdis";
|
\(cdPrefix)node "$PRJ/bin/clawdis.js" \(quotedArgs);
|
||||||
fi;
|
elif command -v pnpm >/dev/null 2>&1; then
|
||||||
if [ -z "$CLI" ]; then echo "clawdis CLI missing on remote host"; exit 127; fi;
|
\(cdPrefix)pnpm --silent clawdis \(quotedArgs);
|
||||||
\(cdPrefix)$CLI \(quotedArgs)
|
else
|
||||||
|
echo "clawdis CLI missing on remote host"; exit 127;
|
||||||
|
fi
|
||||||
"""
|
"""
|
||||||
args.append(contentsOf: ["/bin/sh", "-c", scriptBody])
|
args.append(contentsOf: ["/bin/sh", "-c", scriptBody])
|
||||||
return ["/usr/bin/ssh"] + args
|
return ["/usr/bin/ssh"] + args
|
||||||
|
|||||||
Reference in New Issue
Block a user