【问题标题】:Cordova fastlane xcode 8 configure profileCordova fastlane xcode 8 配置文件
【发布时间】:2017-02-01 05:42:15
【问题描述】:

我尝试在 xcode 8 上通过 fastlane (https://github.com/platanus/fastlane-cordova) 构建我的应用程序 生成 xcode.proj 时,如何在 cordova 中指定选择“正确”的配置文件?

=== BUILD TARGET app OF PROJECT app WITH CONFIGURATION Release ===
[ios] 
[ios] Check dependencies
[ios] Signing for "Eule" requires a development team. Select a development team in the project editor.
[ios] Code signing is required for product type 'Application' in SDK 'iOS 10.0'
[ios] 
[ios] ** BUILD FAILED **
[ios] 
[ios] 
[ios] The following build commands failed:
[ios]   Check dependencies
[ios] (1 failure)
[ios] Error: Error code 65 for command

【问题讨论】:

标签: ios xcode cordova certificate code-signing


【解决方案1】:

我遇到了同样的问题,所以我最终创建了一个Cordova plugin for Fastlane 来解决这个问题。

this blog post或以下查看如何使用它:

使用 Cordova Fastlane 插件

Cordova Fastlane Plugin 添加到您的项目中:

fastlane add_plugin cordova

当被问到Should fastlane modify the Gemfile at path 'Gemfile' for you? (y/n)时,回复y

然后您可以将插件集成到您的 Fastlane 设置中,例如:

platform :ios do
  desc "Deploy ios app on the appstore"

  lane :create do
    produce(app_name: "myapp")
  end

  lane :deploy do
    match(
      type: "appstore",
      git_url: "https://bitbucket.org/Almouro/certificates" # REPLACE WITH YOUR PRIVATE REPO FOR MATCH
    )
    cordova(platform: 'ios') # Using the Cordova Fastlane Plugin
    appstore(ipa: ENV['CORDOVA_IOS_RELEASE_BUILD_PATH'])
  end
end

platform :android do
  desc "Deploy android app on play store"

  lane :deploy do
    cordova(
      platform: 'android',
      keystore_path: './prod.keystore', # REPLACE THESE LINES WITH YOUR KEYSTORE INFORMATION
      keystore_alias: 'prod',
      keystore_password: 'password'
    ) # Cordova Fastlane Plugin
    supply(apk: ENV['CORDOVA_ANDROID_RELEASE_BUILD_PATH'])
  end
end

带有Appfile,例如

app_identifier "com.awesome.app"
apple_id "apple@id.com"
team_id "28323HT"

小菜一碟!

对于 iOS,运行一次fastlane ios create 以在开发者会员中心和 iTunes Connect 上创建您的应用程序。

现在,您只需运行 fastlane ios deployfastlane android deploy 即可部署到商店!

从这里去哪里

  • 您可以通过在 Cordova 应用的根目录运行 fastlane actions cordova 来查看所有插件选项

  • Fastlane docs 非常适合详细了解它如何让您的生活更轻松

  • 如果您对插件有任何问题或改进的想法,请告诉他们here

【讨论】:

  • @leonziyo noo!你能打开an issue on the repo吗?我们会弄清楚的:)
  • 很抱歉,这是我的错误,与此无关。它现在正在工作!
  • @leonziyo 太棒了!很高兴听到它:)
猜你喜欢
  • 1970-01-01
  • 2017-01-28
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2017-02-04
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多