I am trying to download laravel project via composer on microsoft windows 8.1. But I am unable to download because I receive APPDATA COMPOSER_HOME environment variable issue for this I uninstall the composer from my system and try to re install the latest version of composer on windows 8.1 but I still receiving following error
The APPDATA or COMPOSER_HOME environment variable must be set for composer to run correctly
How to solve this problem? I also searched on google but no useful solution found.
If you are on windows, then it would be better to install the composer using their setup: https://getcomposer.org/Composer-Setup.exe
This should take care of installing and setting the paths correctly. If you've installed it manually, run this command to set the path before using composer:
Set COMPOSER_HOME="C:\path\to\where\composer\installed"
try this command bro in your cmd prompt.
SET COMPOSER_HOME="C:\path\to\composer"
composer self-update