[英]Bower - EPERM, unlink error
I'm encountering the below error stack trace, while I try to install "jQuery" using Bower. 我正在遇到下面的错误堆栈跟踪,而我尝试使用Bower安装“jQuery”。 Can someone offer some help?
有人可以提供一些帮助吗?
C:\study\meanApp>bower install jquery --save
bower not-cached git://github.com/jquery/jquery.git#*
bower resolve git://github.com/jquery/jquery.git#*
bower download https://github.com/jquery/jquery/archive/2.1.1.tar.gz
bower retry Download of https://github.com/jquery/jquery/archive/2.1.1.t
ar.gz failed, trying with git..
bower EPERM EPERM, unlink 'C:\Users\UserZ\AppData\Local\Temp\AUserZ\bower\jquery-8680-AaJIqU\archive.tar.gz'
Stack trace:
Error: EPERM, unlink 'C:\Users\UserZ\AppData\Local\Temp\A-UserZ\bower\jqu
ery-8680-AaJIqU\archive.tar.gz'
Console trace:
Trace
at StandardRenderer.error (C:\Users\UserZ\AppData\Roaming\npm\node_module
s\bower\lib\renderers\StandardRenderer.js:72:17)
at Logger.<anonymous> (C:\Users\UserZ\AppData\Roaming\npm\node_modules\bo
wer\bin\bower:110:22)
at Logger.EventEmitter.emit (events.js:95:17)
at Logger.emit (C:\Users\UserZ\AppData\Roaming\npm\node_modules\bower\nod
e_modules\bower-logger\lib\Logger.js:29:39)
at C:\Users\UserZ\AppData\Roaming\npm\node_modules\bower\lib\commands\ind
ex.js:40:20
at _rejected (C:\Users\UserZ\AppData\Roaming\npm\node_modules\bower\node_
modules\q\q.js:797:24)
at C:\Users\UserZ\AppData\Roaming\npm\node_modules\bower\node_modules\q\q
.js:823:30
at Promise.when (C:\Users\UserZ\AppData\Roaming\npm\node_modules\bower\no
de_modules\q\q.js:1035:31)
at Promise.promise.promiseDispatch (C:\Users\UserZ\AppData\Roaming\npm\no
de_modules\bower\node_modules\q\q.js:741:41)
at C:\Users\UserZ\AppData\Roaming\npm\node_modules\bower\node_modules\q\q
.js:557:44
System info:
Bower version: 1.3.9
Node version: 0.10.18
OS: Windows_NT 6.1.7601 ia32
PS: I've gone through the StackOverflow could find nothing related to my error, hence posting this question. PS:我已经通过StackOverflow可以找到与我的错误无关的任何内容,因此发布此问题。
Thanks in advance, Dave 提前谢谢,戴夫
清理缓存为我解决了错误: npm cache clean
I got the same error "EPERM, unlink" but with a different archive. 我得到了相同的错误“EPERM,取消链接”,但有不同的存档。
Running these commands resolved the issue for me: 运行这些命令为我解决了这个问题:
This link is where I saw to use those commands: https://github.com/bower/bower/issues/798 It is the updating of the decompress-zip that has resolved the issue for others as well. 这个链接是我看到使用这些命令的地方: https : //github.com/bower/bower/issues/798解压缩邮件的更新也为其他人解决了问题。
I got this error and ran the bower in verbose mode. 我收到了这个错误并以详细模式运行了凉亭。 And found the error as below:
并发现错误如下:
bower error SELF_SIGNED_CERT_IN_CHAIN
To resolve this, add below line into .bowerrc created in your default home directory. 要解决此问题,请将以下行添加到默认主目录中创建的.bowerrc中。
"strict-ssl": false
Try bower install
again, it should work. 再次尝试
bower install
,它应该工作。
You could try the following sequence. 您可以尝试以下顺序。 It worked for me.
它对我有用。 bower cache clean npm uninstall -g bower npm install -g bower bower install jQuery#2.1.1
bower cache clean npm uninstall -g bower npm install -g bower bower install jQuery#2.1.1
I had a similar problem and i resolved it pretty easily; 我有类似的问题,我很容易解决它; I was trying to bower install while running a server from my machine.
我正试图从我的机器上运行服务器时进行bower安装。 I disconnected the server and IDE (webstorm) and it worked.
我断开了服务器和IDE(webstorm)并且它工作正常。
i also got the same problem and i tried again all uninstalled everything then after i install again gitbash command in gitbash 我也有同样的问题,我再次尝试所有卸载的一切然后我再次安装gitbash命令gitbash
$ npm install -g bower // let it execute
once executed 一旦执行
again command 再次命令
$ bower install bootstrap // let it execute
when executed you got if want more then run more commands :) 执行时如果想要更多则运行更多命令:)
eg 例如
$ bower install script.js
Whenever I encounter this error, what I do is to clean the npm's cache, 每当我遇到这个错误时,我所做的就是清理npm的缓存,
npm cache clean
and if it doesn't work, I uninstall the concerned bower component, and install it again. 如果它不起作用,我卸载相关的bower组件,然后重新安装。
Uninstall your old node (it may be < 0.12.0) 卸载旧节点(可能<0.12.0)
And Install node version > v0.12.0 (In my case v0.12.7) 并安装节点版本> v0.12.0 (在我的情况下为v0.12.7)
Then 然后
npm update npm -g
And 和
bower install
我通过跑步解决了它
bower cache clean
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.