androidflutterinstallationpathsdk

cmdline-tools : could not determine SDK root


C:\Android\sdk\bin>sdkmanager Error: Could not determine SDK root. Error: Either specify it explicitly with --sdk_root= or move this package into its expected location: <sdk>\cmdline-tools\latest\

it shows like this, even after specifying the root in env variables. ANDROID_SDK_ROOT C:\Android\sdk

I am using windows 10 64 bit machine, I want to run flutter without android studio so followed instruction on this page Install Flutter SDK on windows without Android Studio


Solution

  • Since new updates, there are some changes that are not mentioned in the documentation.

    After unzipping the command line tools package, the top-most directory you'll get is cmdline-tools. Rename the unpacked directory from cmdline-tools to tools, and place it under C:/Android/cmdline-tools.

    Now it will look like: C:/Android/cmdline-tools/tools and it will work perfectly.