扫码阅读
手机扫码阅读

企业DevOps之路:iOS 项目构建

218 2024-07-21

我们非常重视原创文章,为尊重知识产权并避免潜在的版权问题,我们在此提供文章的摘要供您初步了解。如果您想要查阅更为详尽的内容,访问作者的公众号页面获取完整文章。

查看原文:企业DevOps之路:iOS 项目构建
文章来源:
BUG弄潮儿
扫码关注公众号
Article Summary

Article Summary

1. Install Keychains and Provisioning Profiles Management Plugin

This section discusses the installation of the Keychains and Provisioning Profiles Management plugin to manage local keychains and iOS certificates. After installation through Manage Jenkins -> Manage Plugins, it is necessary to restart the Tomcat service to activate the plugin.

2. Configure Keychains and Provisioning Profiles Management

The configuration process involves obtaining the login.keychain file from the user's Keychains directory and uploading it to Jenkins. For MacOS 10.12 and later, the login.keychain-db file is used instead. Password and Code Signing Identity fields must be filled with the macOS user's login password and the certificate identifier respectively. The process grants Jenkins access to use the local machine's debugging and issuance certificates for iOS applications. Mobile provision files corresponding to the debugging and Ad Hoc certificates need to be uploaded to Jenkins, and Jenkins will auto-detect the UUID value of the .mobileprovision files for use in the Provisioning Profiles Directory Path.

3. Install Xcode Integration Plugin

The Xcode integration plugin is installed via Manage Jenkins -> Manage Plugins. Similar to the first plugin, a restart of the Tomcat service is required to ensure the plugin is effective.

4. Build IPA

Building an IPA involves creating a new item, configuring the code repository, and adding Xcode build settings. The Development Team ID must be specified, obtainable from the Apple Developer backend. Other settings include selecting 'Clean before build', 'Generate Archive', and 'Pack application, build and sign .ipa'. The Export method, ipa filename pattern (with the possibility of using built-in variables for naming), and Output directory need to be configured. Additionally, under the Code signing & OS X keychain options, one must specify the Keychain path and password, ensuring Jenkins can unlock the keychain for IPA signing.

5. Advanced Xcode Build Options

The Advanced build settings require the specification of the Xcode Project Directory, Xcode Project File (for projects, not workspaces), and Build output directory. Details about the OBJROOT parameter which determines the directory for .a and .hmap files are also provided, with a reference to official documentation for more information on the relationship between OBJROOT, CONFIGURATION_BUILD_DIR, and SYMROOT.

6. Collect IPA Artifacts

The resulting IPA package is typically located in the build directory, which can be referenced as build/**/*.ipa for collection purposes.

想要了解更多内容?

查看原文:企业DevOps之路:iOS 项目构建
文章来源:
BUG弄潮儿
扫码关注公众号