문제

Running on OSX 10.7 (Lion). Tried including as much detail here. I (foolishly?) decided to upgrade to the latest NODE and NPM. I git-ed and curl-ed like a good boy, and ended up with this:

>node -v
v0.5.9
>npm -v
1.0.99

added export NODE_PATH=/usr/local/lib/node_modules:/usr/local/lib/node which yields:

>echo $NODE_PATH
/usr/local/lib/node_modules:/usr/local/lib/node

But every require I have in all my scripts fails in finding any of my modules. It either looks in the local library, or just gives up with an "Error: Cannot find module" message.

I tried variations on the NODE_PATH: with/without the node_modules, with specific directories - nada.

Am I missing some NPM configuration? Am I using it incorrectly? All the scripts worked well prior to the upgrade.

Thanks for any help.

도움이 되었습니까?

해결책

Finally solved it by installing modules locally into the specific node directories.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top