Node.js cannot find /usr/bin/helloworld.js on windows

I installed Node.js on Windows (here binary is here http://node-js.prcn.co.cc/ ) and can successfully create an HTTP server in the console.

Now I put the same instructions in the helloworld.js script in the bin directory and ran with a dos prompt

node helloworld.js 

and it cannot find in / usr / bin. So I put it in the Node.js install directory in usr / bin, but the same message. I finally tried c: / usr / bin, but still failed.

So where should I put my script in windows?

screencopy errors

enter image description here

+3
source share
1 answer

-, Windows , DOS. (, DosBox ), node.js DOS, Windows, DOS LOL. Windows - , , , cmd.exe.

, node.js Cygwin, Cygwin node.js, http://node-js.prcn.co.cc.

, /usr/bin . .js bin - ( Windows) .

example.js bin, console.log( "foo" ), "" - Windows, cd bin node helloworld.js.

, :

1) node -v? , ?

2) (, bin, lib ..) node.exe .7z, ?

3) shell.cmd "" cmd.exe? ( )

+3
source

All Articles