mark mark - 1 year ago 353
JSON Question

EACCES: permission denied, open

bower EACCES EACCES: permission denied, open '/home/caner/.cache/bower/packages/e5ec1b46386aa59c822f27e340f7ab5b-1.5.8.lock'

Stack trace:
Error: EACCES: permission denied, open '/home/caner/.cache/bower/packages/e5ec1b46386aa59c822f27e340f7ab5b-1.5.8.lock'
at Error (native)

Console trace:
at StandardRenderer.error (/home/caner/.npm-global/lib/node_modules/bower/lib/renderers/StandardRenderer.js:81:37)
at Logger.<anonymous> (/home/caner/.npm-global/lib/node_modules/bower/lib/bin/bower.js:110:26)
at emitOne (events.js:90:13)
at Logger.emit (events.js:182:7)
at Logger.emit (/home/caner/.npm-global/lib/node_modules/bower/lib/node_modules/bower-logger/lib/Logger.js:29:39)
at /home/caner/.npm-global/lib/node_modules/bower/lib/commands/index.js:48:20
at _rejected (/home/caner/.npm-global/lib/node_modules/bower/lib/node_modules/q/q.js:844:24)
at /home/caner/.npm-global/lib/node_modules/bower/lib/node_modules/q/q.js:870:30
at Promise.when (/home/caner/.npm-global/lib/node_modules/bower/lib/node_modules/q/q.js:1122:31)
at Promise.promise.promiseDispatch (/home/caner/.npm-global/lib/node_modules/bower/lib/node_modules/q/q.js:788:41)
System info:
Bower version: 1.7.9
Node version: 5.12.0
OS: Linux 4.4.0-38-generic x64

i got this error when i try to install bower with

bower pdate

i tried lots of things.

bower init

but did not work

i first installed npm then try to install bower.

i did most of those

but not working.

what can be reason?

what i want to do is

npm install
npm install -g bower (no need if you have installed bower)
bower install
bower prune
bower update
npm install -g gulp (no need if you have installed gulp)
gulp install

in a project directory

Answer Source

Remove .cache folder first, I guess that .cache folder created with different permissions, it happens when You play with sudo and etc.

So run this:

sudo rm -rf /home/caner/.cache

and after that run Your commands again

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download