Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Composer failed to open stream: Permission denied

am trying to install illuminate/html package in Laravel 5.1 using command composer require illuminate/html . But I get this error.

[ErrorException]                                                             
file_put_contents(C:\ProgramData\ComposerSetup\bin): 
failed to open stream:  Permission denied

require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-update]
[--update-no-dev] [--update-with-dependencies] [--ignore-platform-reqs] 
[--sort-packages] [packages1] ... [packagesN]

I believe Problem is permission to access that folder, I tried to remove read only protection but the protection return by default.

Am running Windows10

like image 254
Josh L. Minga Avatar asked Sep 19 '15 16:09

Josh L. Minga


1 Answers

I had a similar problem recently, and needed to change the permissions of my folders.

By running: php artisan cache:clear chmod -R 777 storage vendor composer dump-autoload

I was able to give all the permissions required to open files and write to them etc

like image 113
James Avatar answered Sep 21 '22 14:09

James