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
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
I had this problem too. I put this solution here in case it works for someone else.
On my system (Windows 10), I had marked both the vendor folder and the composer.json file in my project folder as hidden
, because of reasons. The error message went away when I unhid the folders and the json files, and ran the command again. I did not need to restart my command line in Administrator mode. (In fact, trying this in Administrator mode did not work either, until I changed the file and folder properties to unhidden.)
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.