I'm using Gulp to compile some assets on a simple standalone WordPress theme project.
When I run my gulp task that compiles some LESS files I get the following error:
stream.js:94
throw er; // Unhandled stream error in pipe.
^
Error: EPERM, chmod '/Users/harryg/Sites/sites/wordpress/wp-content/themes/samarkand-2/assets/css/main.min.css'
When I run it as sudo
the task executes without problem.
Thinking it was a permissions error I chmod'd the entire theme folder and its contents to 777 but this doesn't solve the problem. I have gulp installed globally which may be the issue but I'm not sure how to solve.
EDIT
Even if I run the local gulp I get the same error. I.e. running node_modules/.bin/gulp
from my project folder produces the same EPERM error.
`sudo chown -R `whoami` sites/wordpress/wp-content/themes/samarkand-2`
should fix it. Or whatever directory you want to start from. This is no dangerous and might come because of you node-installation. It's pretty common and should be fixed in general after running installs with [email protected]
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With