解决在Win10下 flutter doctor 检测不到android studio中的Flutter插件和Dart插件的问题

之前环境配好之后就没有在动过,今天执行 flutter doctor 发现环境出了点问题

$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 1.20.3, on Microsoft Windows [Version 10.0.17134.1184], locale zh-CN)
[√] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[!] Android Studio (version 3.1)
    X Flutter plugin not installed; this adds Flutter specific functionality.
    X Dart plugin not installed; this adds Dart specific functionality.
    X Unable to find bundled Java version.
[√] Android Studio (version 4.0)
[√] IntelliJ IDEA Community Edition (version 2019.3)
[!] Connected device
    ! No devices available

! Doctor found issues in 2 categories.

搜索引擎找了一圈,都是各种复制粘贴,都是针对mac的处理方法,建立软连接,也有说让卸了重装的,我检查了一下我的android studio 版本,好像有新的,我 Check for Updates 了一下之后,发现我本地竟然有3个版本的 android studio,删掉了2个旧版本,只保留最新的,然后我又执行了一遍 flutter doctor, 发现问题解决了

$ flutter doctor
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel stable, 1.20.3, on Microsoft Windows [Version 10.0.17134.1184], locale zh-CN)
[√] Android toolchain - develop for Android devices (Android SDK version 29.0.2)
[√] Android Studio (version 4.0)
[√] IntelliJ IDEA Community Edition (version 2019.3)
[!] Connected device
    ! No devices available

! Doctor found issues in 1 category.

因为之前我电脑上的 android studio 版本太多,以至于 flutter doctor 不知道要用哪个版本,所以才会找不到 android studio 相关的工具链的问题。

Last modification:December 8th, 2020 at 02:05 pm
If you think my article is useful to you, please feel free to appreciate

Leave a Comment