0

While installing flutter I am getting this error:

Android toolchain - develop for Android devices (Android SDK version 30.0.1)
    X cmdline-tools component is missing
      Run `path/to/sdkmanager --install "cmdline-tools;latest"`

And I saw many solutions but they all use Android Studio, while I am using VSCode.

Rohit Dhingra
  • 11
  • 1
  • 4
  • Please follow this https://stackoverflow.com/questions/68236007/i-am-getting-this-errors-cmdline-tools-component-is-missing-after-installing-f Possible duplictate of this. – Hardik Mehta Nov 10 '21 at 07:15
  • No its not same, its about Android Studio and so easy to locate in it. I am using VSCode so I am not able to solve it. – Rohit Dhingra Nov 10 '21 at 07:22
  • You can install manually from this link depend on the system you are using. https://developer.android.com/studio#command-tools and https://proandroiddev.com/how-to-setup-android-sdk-without-android-studio-6d60d0f2812a – Hardik Mehta Nov 10 '21 at 07:24
  • Yes thank you, it worked. We need to download the command line tools separately and then place it in our ```\AppData\Local\Android\Sdk``` directory. – Rohit Dhingra Nov 10 '21 at 12:41

1 Answers1

2

For my case Installing Command-line Tools form sdk manager solved the problem.

Steps to install from sdkmanager:

  1. Open sdk manager in Android Studio
  2. Select SDK Tools tab
  3. Select Android SDK Command-line Tools and then apply

Steps

You can download command-line tools manually and place it on sdk folder. That also should work.