I am getting error cmdline-tools component is missing after installing Flutter and Android Studio... I added the Android SDK. How can I solve them?
The solution for me was opening Android Studio and going to SDK Manager, switch to the SDK Tools tab and check Android SDK Command-line Tools (latest).
Don't forget to add to your PATH the tools and platform-tools folder that are inside your SDK.
I'm getting the error 'cmdline-tools component is missing and Android license status unknown , when i run the command flutter doctor
I was able to solve the issue using the following steps.
- Updating the SDK in the Android Studio.
- Updating the SDK tools in the Android Studio.
- Downloading the Android SDK Command line Tools.
I followed this article : https://flutter-developer.medium.com/flutter-flutter-doctor-results-with-cmdline-tools-component-is-missing-f6371a9c6e97
In Android Studio cmdline-tools component is missing
It was needing to restart the PC
Flutter doctor results with cmdline-tools component is missing
You can follow below steps in order to ensure proper working of your flutter project:
your sdk manager should look something like this:
1. Installing Android SDK Command-line Tools in Android Studio:
Preferences
> Appearance & Behavior
> System Settings
> Android SDK
> SDK Tools
>
install these 3 tools:
Android SDK Command-line Tools (latest)
Android SDK Build Tools 31
Android SDK Platform tools (latest version 31)
and make sure every tools must be of same latest version in order to avoid any error as there might be new updates later on.
2. Also make sure to Accept Android Licences by running below command in your cmd:
flutter doctor --android-licenses
if anything above didn't worked out make sure you have set the proper JDK/JRE locations in environment variables in system settings of windows:
Add below path in your System environment path variable for user variable as well as your system variable:
C:\Program Files\Java\jdkXXXXX\bin
here XXX is your version and this should be added in your sys var and user both
C:\Users\Neha\AppData\Local\Android\Sdk\tools
C:\Users\Neha\AppData\Local\Android\Sdk\build-tools
C:\Users\Neha\AppData\Local\Android\Sdk\platform-tools
the above three paths should be added in your user variable path
check two screenshots attached below for proper path settings.
I have added android studio's tools path also so do that as I have done in screenshot.
This one is for user variable path:
This one is for system variable path:
Follow source to learn more about setting the path for java:
Related Topics
How to Switch Between Hide and View Password
How to Create Colorstatelist Programmatically
Detect 7 Inch and 10 Inch Tablet Programmatically
Integrate Zxing in Android Studio
Android Viewmodel Additional Arguments
Disable Orange Outline Highlight on Focus
How to Get a Dialog Style Activity Window to Fill the Screen
How to Measure Height, Width and Distance of Object Using Camera
Recyclerview Changing Items During Scroll
How to Display a List of Images in a Listview in Android
Can't Include C++ Headers Like Vector in Android Ndk
How to Add New Column to Android SQLite Database
Can't Accept License Agreement Android Sdk Platform 24
Customize Android Intent.Action_Send
Android - How to Achieve Setonclicklistener in Kotlin
Fragment Oncreateview and Onactivitycreated Called Twice
Completely Transparent Status Bar and Navigation Bar on Lollipop