npm install

今天在npm install的时候出现了如下错误:

npm ERR! install Couldn't read dependencies

npm ERR! Failed to parse json

npm ERR! Unexpected token /

npm ERR! File: /Users/mac/project/test/package.json

npm ERR! Failed to parse package.json data.

npm ERR! package.json must be actual JSON, not just JavaScript.

npm ERR!

npm ERR! This is not a bug in npm.

npm ERR! Tell the package author to fix their package.json file. JSON.parse

 

npm ERR! System Darwin 11.4.0

npm ERR! command "node" "/usr/local/bin/npm" "install"

npm ERR! cwd /Users/mac/project/test

npm ERR! node -v v0.8.9

npm ERR! npm -v 1.1.61

npm ERR! file /Users/mac/project/test/package.json

npm ERR! code EJSONPARSE

npm ERR!

npm ERR! Additional logging details can be found in:

npm ERR!     /Users/mac/project/test/npm-debug.log

npm ERR! not ok code 0

在网上查了一下,发现是因为package.json这个文件里面有注释,只要把这些注释删掉就ok了

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值