darlinghq / darling

Darwin/macOS emulation layer for Linux
http://www.darlinghq.org
GNU General Public License v3.0
11.55k stars 446 forks source link

can not exec: "darling shell command arg" with nodejs exec function #1404

Open conganwoz opened 1 year ago

conganwoz commented 1 year ago

Expected Result What did you expect to happen? function exec() should run normal as run command in normal shell Actual Result What did happen? receive error with code = 1 Steps To Reproduce

  1. create simple node project that create build-in command to shell
  2. create command by using: npm install -g .
  3. run darling shell command arg using exec function require from "child_process" System Information What system are you using?
Software Version
Linux Kernel 5.10.0
facekapow commented 1 year ago

Could you perhaps provide some sample code for what you're trying to do? I don't quite understand whether you're trying to use Node.js within Darling or outside of Darling to execute a command within Darling.