【发布时间】:2014-10-11 16:45:06
【问题描述】:
我正在使用 yeoman 作为脚手架工具,但出现以下错误。谁能帮我解决这个问题。我使用的是 windows 8 环境。
karma-jasmine@0.1.5 node_modules\karma-jasmine
npm WARN optional dep failed, continuing imagemin-optipng@1.0.0
npm WARN optional dep failed, continuing imagemin-jpegtran@1.0.0
npm ERR! EEXIST, open 'C:\Users\shouvik-usr\AppData\Roaming\npm-cache\4230a95c-m
-cache-lodash-2-4-1-package-tgz.lock'
File exists: C:\Users\shouvik-usr\AppData\Roaming\npm-cache\4230a95c-m-cache-lod
ash-2-4-1-package-tgz.lock
Move it away, and try again.
npm ERR! System Windows_NT 6.2.9200
npm ERR! command "C:\\Program Files (x86)\\nodejs\\\\node.exe" "C:\\Program File
s (x86)\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "install"
npm ERR! cwd C:\Shouvik Data\work\try
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! path C:\Users\shouvik-usr\AppData\Roaming\npm-cache\4230a95c-m-cache-lo
dash-2-4-1-package-tgz.lock
npm ERR! code EEXIST
npm ERR! errno 47
npm ERR! not ok code 0
【问题讨论】:
-
你做到了吗?删除锁定文件
C:\Users\shouvik-usr\AppData\Roaming\npm-cache\4230a95c-m -cache-lodash-2-4-1-package-tgz.lock(可能是之前失败的遗留物)。 -
是的,我也尝试过这样做。它没有帮助。
-
尝试以管理员身份在 shell 中运行它