如何仅从package-lock.json安装npm依赖项?

时间:2019-07-11 17:32:52

标签: node.js npm

我已经运行了npm install js-yaml之类的命令,现在已经生成了package-lock.json文件。

然后如何使用此文件重新安装依赖项?

chris@instance-1:~/fuck3$ npm ci
npm ERR! path /home/chris/fuck3/package.json
npm ERR! code ENOENT
npm ERR! errno -2
npm ERR! syscall open
npm ERR! enoent ENOENT: no such file or directory, open '/home/chris/fuck3/package.json'
npm ERR! enoent This is related to npm not being able to find a file.
npm ERR! enoent 

npm ERR! A complete log of this run can be found in:
npm ERR!     /home/chris/.npm/_logs/2019-07-11T17_31_26_335Z-debug.log
chris@instance-1:~/fuck3$ ls
index.js  job.yaml  package-lock.json

0 个答案:

没有答案