Git Product home page Git Product logo

Comments (6)

zaggino avatar zaggino commented on May 15, 2024

Debugging, actual parameters send to the original child_process.spawn are:

command: "C:\Windows\system32\cmd.exe"
args: [ '/s',
  '/c',
  '"c:\\Program^ Files\\iojs\\node.exe "--version""' ]

from node-cross-spawn.

satazor avatar satazor commented on May 15, 2024

@zaggino so it works if you execute from c:\ but not from d:?

from node-cross-spawn.

zaggino avatar zaggino commented on May 15, 2024

No, doesn't matter where you execute it from. I've moved the test files to C:\test:

Zaggi@ZAGGI-PC /c/test
$ pwd
/c/test

Zaggi@ZAGGI-PC /c/test
$ node test.js
C:\Windows\system32\cmd.exe
[ '/s',
  '/c',
  '"c:\\Program^ Files\\iojs\\node.exe "--version""' ]
stderr: module.js:318
    throw err;
          ^
Error: Cannot find module 'C:\test\Files\iojs\node.exe'
    at Function.Module._resolveFilename (module.js:316:15)
    at Function.Module._load (module.js:258:25)
    at Function.Module.runMain (module.js:451:10)
    at startup (node.js:123:18)
    at node.js:868:3

child process exited with code 1

from node-cross-spawn.

zaggino avatar zaggino commented on May 15, 2024

I don't know the exact magic behind using cmd.exe but it probably shouldn't be used for other .exe files?

from node-cross-spawn.

satazor avatar satazor commented on May 15, 2024

Should be fixed now! Thanks for the report.

from node-cross-spawn.

zaggino avatar zaggino commented on May 15, 2024

Thanks, confirmed fixed in 0.2.8

from node-cross-spawn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.