【问题标题】:Flutter doctor not recognized iPhone whereas Xcode doesFlutter 医生无法识别 iPhone 而 Xcode 可以
【发布时间】:2019-09-23 17:43:21
【问题描述】:

我在我的 Mac (macOS 10.14.6) 上设置了 Flutter 工作流程,我可以创建一个项目,使用 Xcode/Android/VsCode 并在模拟器上运行我的项目。 但是,我无法在自己的 iOS 设备 (Iphone 7) 上运行我的项目。

每次我运行命令行flutter doctor 我都会收到消息No devices available,我准确地说我已经完成了 Flutter 官方文档中的所有安装说明。 flutter - macOS install

我还准确地说我的 iPhone 运行的是 iOS 13。 有什么想法吗?

[✓] Flutter (Channel stable, v1.9.1+hotfix.2, on Mac OS X 10.14.6 18G95, locale en-FR)
    • Flutter version 1.9.1+hotfix.2 at /Users/louisbertin/flutter
    • Framework revision 2d2a1ffec9 (2 weeks ago), 2019-09-06 18:39:49 -0700
    • Engine revision b863200c37
    • Dart version 2.5.0

[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    • Android SDK at /Users/louisbertin/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-28, build-tools 28.0.3
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 11.0, Build version 11A420a
    • CocoaPods version 1.7.5

[✓] Android Studio (version 3.5)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 39.0.3
    • Dart plugin version 191.8423
    • Java version OpenJDK Runtime Environment (build 1.8.0_202-release-1483-b49-5587405)

[!] IntelliJ IDEA Ultimate Edition (version 2019.1.3)
    • IntelliJ at /Applications/IntelliJ IDEA.app
    ✗ Flutter plugin not installed; this adds Flutter specific functionality.
    ✗ Dart plugin not installed; this adds Dart specific functionality.
    • For information about installing plugins, see
      https://flutter.dev/intellij-setup/#installing-the-plugins

[✓] VS Code (version 1.38.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.4.1

[!] Connected device
    ! No devices available

【问题讨论】:

  • 你找到解决办法了吗?
  • 嗨@MiguelRuivo!绝望..我没有找到任何解决这个问题的方法..也许我应该尝试使用最新版本的 Flutter
  • 实际上在完全重新安装 Flutter 后,它开始工作了。我相信我有一些丢失的文件(现在不记得是哪个)可能已经被删除了。
  • 这几天我会重新安装Flutter,我会回来告诉你它是否有效。
  • 当我重新安装颤振时,终于一切正常。但是,VsCode 的内存消耗很大,所以我切换到 Android Studio。它的内存消耗更好..但是如果您有任何改进的想法,我可能会感兴趣!

标签: ios flutter


【解决方案1】:

运行此命令为我修复了它。

sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer

我的问题发生在我更新我的 Xcode 之后。我希望你会发现它也很有用。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2022-11-04
    • 2022-08-21
    • 2012-07-12
    • 2014-07-06
    • 2018-05-02
    相关资源
    最近更新 更多