在macOS Monterey v12.1中,当我使用dart命令时,它会显示“”。
Doctor summary (to see all details, run flutter doctor -v):
[✓] Flutter (Channel master, 2.9.0-1.0.pre.491, on macOS 12.1 21C52 darwin-x64, locale en-CN)
[✓] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[✓] Xcode - develop for iOS and macOS (Xcode 13.2.1)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2020.3)
[✗] Cannot determine if IntelliJ is installed
✗ Directory listing failed
[✓] VS Code (version 1.63.2)
[✓] VS Code (version 1.63.2)
[✓] Connected device (1 available)
[!] HTTP Host Availability
✗ HTTP host https://maven.google.com/ is not reachable. Reason: An error occurred while checking the HTTP host: Operation timed out
! Doctor found issues in 2 categories.
2条答案
按热度按时间1mrurvl11#
关于许可的一些事情,这个命令解决了我的问题。
laximzn52#
当我看到在vscode dart扩展页面中指定/突出显示了一个env时,我发现了一些有趣的解决方案。在我添加了env FLUTTER_ROOT(flutter sdk路径)后,错误不再存在。
希望这能有所帮助