bevry / cson

CoffeeScript-Object-Notation. Same as JSON but for CoffeeScript objects.
Other
1.34k stars 56 forks source link

install on windows 7 fails #50

Closed kitsguru closed 10 years ago

kitsguru commented 10 years ago

I was trying to install another package that depends on cson and received an error. When I try to install cson by itself, I receive the same error.

I don't understand why it reports "'node' is not recognized as an internal or external command,"

20:10 > node -v
v0.10.32

20:13 > npm -version
1.4.28

20:09 > npm install cson
|
> cson@1.6.1 preinstall J:\@projects\testing\node_modules\cson
> node ./cyclic.js

'node' is not recognized as an internal or external command,
operable program or batch file.

npm ERR! cson@1.6.1 preinstall: `node ./cyclic.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the cson@1.6.1 preinstall script.
npm ERR! This is most likely a problem with the cson package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node ./cyclic.js
npm ERR! You can get their info via:
npm ERR!     npm owner ls cson
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "c:\\Program Files\\nodejs\\node.exe" "c:\\Program Files\\nodej
s\\node_modules\\npm\\bin\\npm-cli.js" "install" "cson"
npm ERR! cwd J:\@projects\testing
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! code ELIFECYCLE
npm ERR! not ok code 0
bluSCALE4 commented 10 years ago

A colleague is facing the same issue sans the "'node' is not rec...".

npm ERR! cson@1.6.1 preinstall: `node ./cyclic.js`
npm ERR! spawn ENOENT
npm ERR!
npm ERR! Failed at the cson@1.6.1 preinstall script.
npm ERR! This is most likely a problem with the cson package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR!     node ./cyclic.js
npm ERR! You can get their info via:
npm ERR!     npm owner ls cson
npm ERR! There is likely additional logging output above.
npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\n
pm\\bin\\npm-cli.js" "install"
npm ERR! cwd C:\...\src\main\web
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! syscall spawn
npm ERR! code ELIFECYCLE
npm ERR! errno ENOENT
npm ERR! Error: ENOENT, open 'C:\...\src\main\web\no
de_modules\grunt-replace\node_modules\applause\node_modules\js-yaml\test\unported\invalid-tag-handle
-1.emitter-error'
npm ERR! If you need help, you may report this *entire* log,
npm ERR! including the npm and node versions, at:
npm ERR!     <http://github.com/npm/npm/issues>

npm ERR! System Windows_NT 6.1.7601
npm ERR! command "C:\\Program Files\\nodejs\\\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\n
pm\\bin\\npm-cli.js" "install"
npm ERR! cwd C:\...\src\main\web
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! path C:\...\src\main\web\node_modules\grunt
-replace\node_modules\applause\node_modules\js-yaml\test\unported\invalid-tag-handle-1.emitter-error

npm ERR! code ENOENT
npm ERR! errno 34
pflannery commented 10 years ago

it works for me on windows 7 and 8.

It sounds like you might have a path env issue... Are you running node from the command prompt? i.e. node -v also what terminal do you use powershell, cmd or bash etc...?

Check that your user variables path has: C:\Users\%%YOURUSERNAME%%\AppData\Roaming\npm, also make sure this path exists

and then that your system variables path env has C:\Program Files\nodejs\ for 64bit node or C:\Program Files (x86)\nodejs\ for 32bit node

bluSCALE4 commented 10 years ago

@pflannery thanks. Yes, we're running it from the command prompt. Node is installed right and the environment variable is set. It installs a ton of packages fine, it just gets held up with grunt-replace when it tries to install cson. grunt-replace@0.7.8 and grunt-replace@0.7.9 both fail.

kitsguru commented 10 years ago

using bash, but all paths are correct. Node runs fine from the command prompt. All packages install fine except those with cson dependancy. Fails on node 26, 28 & 32

kitsguru commented 10 years ago

GOT IT Way back when I install NVMW as a node package manager. It used a cmd_auto_run.bat file that set the path variable. This overrode the ENV settings. I commented out the set path in the bat file and all is now OK.

The strange thing is that the values for the PATH were the same.