开发者

Installing node packages / dependencies using npm on Windows Server 2008

开发者 https://www.devze.com 2023-04-11 20:01 出处:网络
I downloaded the node js binaries for windows, it contains all the cygwin dependencies, etc. So I can cd to the C:\\Program Files (x86)\\node\\bin folder and run \'shell\' then \'node npm install\' a

I downloaded the node js binaries for windows, it contains all the cygwin dependencies, etc.

So I can cd to the C:\Program Files (x86)\node\bin folder and run 'shell' then 'node npm install' and the command works.

What exactly do I point it to? I tried pointing it to the packages .tar.gz / .zip or the extracted folder as per the documentation but I receive several errors,

C:\Program Files (x86)\node\bin>node npm install andris9-Nodemailer-10eb182
npm ERR! tar -cvf - <file list elided> execvp(): No such file or directory
npm ERR! tar -cvf - <file list elided>
npm ERR! Failed creating the tarbal开发者_如何学JAVAl.

npm not ok

How is this most simply done in Windows? Read many tutorials but they all vary in explanation and none seem to work.

If there is a simpler way to just reference dependencies from my main .js file that would help too.

Thanks.


I would imagine that you should be able to just download the source and put the libraries in manually.

From NPM:

locally —- This installs your package in the current working directory. Node modules go in ./node_modules, executables go in ./node_modules/.bin/, and man pages aren’t installed at all.

I'm pretty sure that would work.. i think.

0

精彩评论

暂无评论...
验证码 换一张
取 消

关注公众号