The Flutter Directory Is Not A Clone of GitHub Project
Flutter checks for a git folder, which is normally a hidden folder. If you copied and pasted the contents of the zip file, there is a good chance that you missed copying this hidden folder.
You can solve this by doing one of the following:
- Unzip the folder directly to where you want Flutter, or
- Copy the outer folder (
flutter
) to include all the hidden files inside, or - Show all hidden files before selecting them and copying.
I solved this by using this command:
git clone -b beta https://github.com/flutter/flutter.git
(Note: make sure you have git installed.)
After that, try to open flutter_console.bat
and type any flutter command to check whether it is installed properly or not.
I was having this problem even using git to download it. The solution was to change the folder name from .github to .git In windows I did the following.
rename .github .git