如何 select 开发团队 iOS 应用程序在 Flutter 中创建

How to select Development team for iOS app created in Flutter

我正在尝试使用 Google 的 Flutter 将 iOS 应用程序部署到设备,但我在命令行上收到此错误:

Building an iOS app requires a selected Development Team with a Provisioning Profile
Please ensure that a Development Team is selected by:
  1- Opening the Flutter project's Xcode target with
       open ios/Runner.xcworkspace
  2- Select the 'Runner' project in the navigator then the 'Runner' target
     in the project settings
  3- In the 'General' tab, make sure a 'Development Team' is selected
For more information, please visit:
  https://flutter.io/setup/#deploy-to-ios-devices
Or run on an iOS simulator

在哪里以及如何执行此操作?项目中没有"ios/Runner.xcworkspace"。我知道安装的证书和配置文件适用于我的 Mac,因为我使用 Appcelerator 在我的 iOS 设备上创建并安装了一个应用程序,它找到了我需要的一切,运行 完美地设备。

open ios/Runner.xcodeproj 并遵循相同的说明应该行得通吗? Runner.xcodeworkspace 是对模板的一个相对较新的添加,旨在让 Flutter 项目更好地与 CocoaPods 集成。

如果这不起作用,请告诉我们。

您必须在 'signing' 使用您的 Apple ID 登录。之后你可以 select 年 'personal team'。

Select Runner,然后导航到 Signing & Capabilities,在签名下,选中 Automatically manage signing,然后从列表中选择一个 Team,然后您'重做。

对于物理 iOS 设备,情况稍微复杂一些。假设设备通过USB数据线连接并解锁(记住连接数据线后的附加按键提示),我们首先需要打开Xcode中的iOS模块:

在 Xcode select 左侧导航面板中的 Runner 项目中。在 Runner 目标设置页面中,确保您的开发团队在 Signing & Capabilities > All > Team 下 selected。当您 select 一个团队时,Xcode 创建并下载开发证书,使用您的帐户注册您的设备,并创建和下载配置文件(如果需要)。

自动签名 自动签名是一个 target-setting,允许 Xcode 为您管理签名资产。签名设置位于项目编辑器中签名标题下的常规窗格中。要启用自动签名,select“自动管理签名。”

如果您启用自动签名,Xcode 会在需要时为您执行以下操作:

  • 创建您的签名证书

  • 注册连接的设备

  • 创建和编辑 App ID

  • 管理配置文件

  • 编辑权利和信息属性 列表文件

如果您选择手动签名,则需要在 developer.apple.com/account 登录您的开发者帐户以自行执行其中一些步骤。