迦太基建筑计划使Bitrise在90分钟后超时

时间:2019-10-22 08:27:26

标签: ios carthage bitrise

我正在使用Bitrise,并且已将我的开发机器和Bitrise堆栈都更新为Xcode 11。

运行构建时,需要重新生成Carthage依赖关系,并且由于我使用的是AWS依赖关系,即使在我的Mac book pro中,它们也花费很长时间构建,并且使Bitrise构建超时。

这里有一个有关如何配置我的bitrise.yml的示例:

...
workflows:
  test:
    steps:
    - gitlab-status:
        run_if: not (enveq "BITRISE_GIT_COMMIT" "")
        inputs:
        - private_token: "$GITLAB_STATUS_TOKEN"
        - preset_status: running
        - api_base_url: https://gitlab.company.cloud/api/v4
    - activate-ssh-key:
        run_if: '{{getenv "SSH_RSA_PRIVATE_KEY" | ne ""}}'
    - git-clone: {}
    - cache-pull:
        inputs:
        - is_debug_mode: 'true'
    - certificate-and-profile-installer: {}
    - carthage:
        inputs:
        - verbose_log: 'yes'
        - carthage_options: "--platform ios --no-use-binaries --cache-builds"
    - cocoapods-install: {}
    - xcode-test:
        inputs:
        - scheme: CompanyApp
        - project_path: CompanyApp.xcworkspace
        - simulator_device: iPhone 8
    - xcode-test:
        inputs:
        - project_path: CompanyApp.xcworkspace
        - simulator_device: iPhone 8
        - scheme: CompanyAppUITests
    - gitlab-status:
        run_if: not (enveq "BITRISE_GIT_COMMIT" "")
        inputs:
        - private_token: "$GITLAB_STATUS_TOKEN"
        - api_base_url: https://gitlab.company.cloud/api/v4
    - cache-push:
        is_always_run: true
        inputs:
        - is_debug_mode: 'true'
    - deploy-to-bitrise-io: {}
...

以防万一,它们是构建日志的最后两行

*** Building scheme "AWSLogs" in AWSiOSSDKv2.xcodeproj
*** Building scheme "AWSMachineLearning" in AWSiOSSDKv2.xcodeproj

任何想法?

2 个答案:

答案 0 :(得分:2)

解决方案是不要在CI中重建库,将它们添加到存储库并跳过CI中的构建部分后,您会发现构建时间大大减少。

答案 1 :(得分:0)

尝试删除--no-use-binaries

通过选择不使用二进制文件,大的依赖项无法为您提供预编译的二进制文件,从而大大减少了编译时间。如果删除该标志,则应注意编译速度加快。