How to install Android SDK commandline tool on a Ubuntu remote server which doesn't have Display/GUI. When I run, 'flutter upgrade' it gives me the below and I wanted to know if I can use Android SDK commandline tool for resolving the issue.
$flutter upgrade Upgrading Flutter from /home/yvelumani/flutterDev/sdk/flutter... Building flutter tool...` Upgrading engine... Downloading Android Maven dependencies... Failed to download the Android dependencies Downloading Android Maven dependencies... 127.7s (!) Flutter 1.22.0-10.0.pre.133 • channel master • https://github.com/flutter/flutter.git Framework • revision 577de1c44e (46 minutes ago) • 2020-09-10 15:55:03 -0700 Engine • revision fee6f9e533 Tools • Dart 2.10.0 (build 2.10.0-110.0.dev) Running flutter doctor... Doctor summary (to see all details, run flutter doctor -v): [✓] Flutter (Channel master, 1.22.0-10.0.pre.133, on Linux, locale en_US.UTF-8) [!] Android toolchain - develop for Android devices ✗ Unable to locate Android SDK. Install Android Studio from: https://developer.android.com/studio/index.html On first launch it will assist you in installing the Android SDK components. (or visit https://flutter.dev/docs/get-started/install/linux#android-setup for detailed instructions). If the Android SDK has been installed to a custom location, set ANDROID_HOME to that location. You may also want to add it to your PATH environment variable. ✗ Android SDK file not found: adb. [!] Android Studio (not installed) [✓] Proxy Configuration [!] Connected device ! No devices available ! Doctor found issues in 3 categories. I have downloaded android SDK commandline tool from https://developer.android.com/studio#command-tools. But I am not sure how to install this tool and what path to be chosen as ANDROID_HOME?
NOTE: I am not going/able to use Android Studio for my app development.
Thanks for the help in advance.