[英]Couldn't read dependencies npm install on windows
I got the annoying error when try to put dependencies via npm on windows. 当尝试通过npm在Windows上放置依赖项时,出现了烦人的错误。 I gave correct name to package.json.
我给package.json指定了正确的名称。 Help me !
帮我 !
D:\sitenode>npm install
npm ERR! install Couldn't read dependencies
npm ERR! Error: Invalid version: "0.1"
npm ERR! at Object.module.exports.fixVersionField (C:\Program Files\nodejs\n
ode_modules\npm\node_modules\read-package-json\node_modules\normalize-package-da
ta\lib\fixer.js:183:13)
You need to fix your string with semantic versioning. 您需要使用语义版本控制来修复字符串。 every version must be come with .
每个版本都必须随附。 .* style (three digits).
。*样式(三位数)。 so I changed your package.json and it's work
所以我改变了你的package.json就可以了
{ "name" : "SiteWithNode",
"version" : "0.0.1",
"private" : "true",
"dependencies" : {
"express" : "*.*.*",
"jade" : "*.*.*",
"stylus" : "*.*.*",
"nib" : "*.*.*"
}
}
of course you might want to config (setup to fix certain versions due to compatibility). 当然,您可能需要配置(由于兼容性,安装程序可以修复某些版本)。 You might want to take a look at here
您可能要在这里看看
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.