I am trying to start my cli tool via the package.json bin
property.
I have the following:
...
\"name\": \"mycli\",
\"bin\": \"./bin/mycli\",
Answer from Rodrigo Medeiros works for me, but only if I have too the shebang line at the .js file.
There I had another issue. I have node.js installed at c:\Program files\nodejs, and this was my shebang line:
#!c:/program files/nodejs/node
This didn't work, because the blank space. This was the correct one:
#!c:/progra~1/nodejs/node