Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to locate the android sdk flutter

I installed visual_stdio_code and trying to run "flutter doctor" then this is the error.
and when I run flutter doctor on Command Line and this is answer that I have:

flutter devices Unable to locate a development device; please run 'flutter doctor' for information about installing additional components.

Any help please!

enter image description here

enter image description here

like image 507
Pavan Kumar Avatar asked Nov 27 '22 16:11

Pavan Kumar


2 Answers

Here's another solution just in case the answer above doesn't work.

Open Android Studio then click on SDK Manager (down-pointing arrow)

This should open a new box with your Android SDK Location at the top. It should look like this:

/Users/your-name/Library/Android/sdk

Copy that path, head to the Terminal and type this:

flutter config --android-sdk /Users/your-name/Library/Android/sdk

Next run:

flutter doctor --android-licenses

You can run flutter doctor to verify

That should help.

like image 90
olivrg Avatar answered Dec 22 '22 10:12

olivrg


Step-1

Config the path of android-sdk:

# use `$ANDROID_HOME` if your android-sdk path is not below
$ flutter config --android-sdk /usr/local/share/android-sdk

Step-2

Add android-license to flutter

$ flutter doctor --android-licenses

Step-3

Check if it works

$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel master, v1.3.3-pre.18, on Mac OS X 10.14.3 18D109, locale en-US)
[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
[✓] iOS toolchain - develop for iOS devices (Xcode 10.1)
[✓] Android Studio (version 3.3)
[✓] Connected device (2 available)

• No issues found!
like image 21
clearloop Avatar answered Dec 22 '22 09:12

clearloop