[英]Can't change flutter android-sdk path
I'm setting up flutter in my laptop (Elementary OS), the case is I'm trying to be able develop flutter without Android Studio and using VSCode to make it lightweight, the step I did is installing flutter, download manually android-sdk, and move it to usr/lib/Android
, install gradle, and openJDK8,我正在我的笔记本电脑(Elementary OS)中设置 flutter,情况是我试图在没有 Android Studio 的情况下开发 flutter 并使用 VSCode 使其轻量级,我所做的步骤是安装 flutter,手动下载 android-sdk ,并将其移动到usr/lib/Android
,安装 gradle 和 openJDK8,
I did setting up Android Environtment, export ANDROID_HOME
to usr/lib/Android
, setting up with sdkmanager
to download system-images, etc我确实设置了 Android 环境,将ANDROID_HOME
导出到usr/lib/Android
,设置了sdkmanager
以下载系统映像等
I can run the flutter command on terminal, the problem is in the android-sdk
path, I already changed the config with flutter config --android-sdk /usr/lib/Android
, but, the flutter doctor -v
command shows我可以在终端上运行 flutter 命令,问题出在android-sdk
路径中,我已经使用flutter config --android-sdk /usr/lib/Android
更改了配置,但是, flutter doctor -v
命令显示
[!] Android toolchain - develop for Android devices
• Android SDK at /usr/lib/android-sdk
• Android NDK location not configured (optional; useful for native profiling support)
✗ 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/setup/#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.
and the flutter config
command shows并且flutter config
命令显示
Settings:
android-sdk: /usr/lib/Android/
HAPPY CODING :)快乐编码:)
You can add Android SDK to path variable.您可以将Android SDK添加到路径变量。
Add ...\\AndroidSDK\\platform-tools
to your path.将...\\AndroidSDK\\platform-tools
到您的路径中。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.