简体   繁体   English

使用健身房创建 ipa 时,Fastlane 不起作用

[英]Fastlane not working when creating ipa with gym

I'm using Fastlane to automatically generate an IPA.我正在使用 Fastlane 自动生成 IPA。 I have a provisioning profile and a production certificate from a team of which I am a member (but not an administrator).我有一个供应配置文件和一个来自我是其中成员(但不是管理员)的团队的生产证书。

The problem arises when I try to generate the IPA with Fastlane, which does not find the certificate and tries to download a new one.当我尝试使用 Fastlane 生成 IPA 时出现问题,它没有找到证书并尝试下载新证书。 As I am not an administrator, I am not allowed to download another certificate and the operation returns an error.由于我不是管理员,我不允许下载其他证书并且操作返回错误。

I tried adding the option "skip_certificate_verification" in the hope that the verification was failing but could be signed if continued.我尝试添加选项“skip_certificate_verification”,希望验证失败但如果继续可以签名。 In doing so something interesting happens, because it seems that the entire generation process is executed and even the file comes to appear in the Organizer window of the Xcode, but returns error saying that it has not found a profile for this id app (even though at the beginning of the operation the logs say that the provisioning profile has been downloaded and installed correctly).这样做时会发生一些有趣的事情,因为似乎整个生成过程都被执行了,甚至文件也出现在 Xcode 的管理器窗口中,但返回错误说它没有找到这个 id 应用程序的配置文件(即使在操作开始时,日志说已正确下载并安装了配置文件)。

Here's my Fastfile这是我的 Fastfile

default_platform(:ios)

platform :ios do

  lane :docuten_release do
      sigh(development:false,
        cert_id:"CERTID",
        filename:"my_profile.mobileprovision",
        ignore_profiles_with_different_name:true,
        skip_certificate_verification:true)
      gym(
        scheme: "MyScheme",
        workspace: "myapp.xcworkspace",
        output_directory: ".",
        configuration: "Release"
      )
  end

end

Searching in the logs the main error seems to be:在日志中搜索主要错误似乎是:

Code Signing Error: No profiles for 'com.company.myapp' were found: Xcode couldn't find any iOS App Development provisioning profiles matching 'com.company.myapp'.代码签名错误:找不到“com.company.myapp”的配置文件:Xcode 找不到任何与“com.company.myapp”匹配的 iOS 应用开发配置文件。 Automatic signing is disabled and unable to generate a profile.自动签名已禁用且无法生成配置文件。 To enable automatic signing, pass -allowProvisioningUpdates to xcodebuild.要启用自动签名,请将 -allowProvisioningUpdates 传递给 xcodebuild。 Code Signing Error: Code signing is required for product type 'Application' in SDK 'iOS 11.3'代码签名错误:SDK“iOS 11.3”中的产品类型“应用程序”需要代码签名

Is "Automatically manage signing" enabled in your Xcode project?您的 Xcode 项目中是否启用了“自动管理签名”? If it is, you need to add export_xcargs: "-allowProvisioningUpdates" to your call to gym as described in the Fastlane Docs .如果是,您需要将export_xcargs: "-allowProvisioningUpdates"添加到您对gym的调用中,如Fastlane Docs 中所述

It is also stated in the error message that is presented to you 🙃它也在提供给您的错误消息中说明🙃

To enable automatic signing, pass -allowProvisioningUpdates to xcodebuild.要启用自动签名,请将 -allowProvisioningUpdates 传递给 xcodebuild。 Code Signing Error: Code signing is required for product type 'Application' in SDK 'iOS 11.3'代码签名错误:SDK“iOS 11.3”中的产品类型“应用程序”需要代码签名

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM