Giter VIP home page Giter VIP logo

iosautoarchivescript's Introduction

iOSAutoArchiveScript

本脚本修改自:https://github.com/jkpang/PPAutoPackageScript,十分感谢该作者!

更新了 Xcode 9

Xcode 8版本点这

现已经更新到 Xcode 9!

Xcode 9 的 xcodebuild 自动打包工具做了调整

  • Xcode 9 将不会允许你访问钥匙串里的内容,除非设置 -allowProvisioningUpdates详情请看

  • ExportOptions.plist 需要添加新的 Key-Value:

     <key>provisioningProfiles</key>
     	<dict>
     		<key>你的 Bundle ID</key>
     		<string>对应的PP描述文件的名称</string>
     	</dict>
     <key>teamID</key>
     <string>你的 teamID</string>
    

注意

## 注意:不能使用 ruby 2.4.0 运行该脚本

该脚本在最新的 Ruby 2.4.0 下运行会出错(在 macOS 10.12.3 或是 10.12.4 下会编译失败,系统更新到 macOS 10.12.5 后,一切正常)

若是编译错误(一般是在导出 .ipa 包这一步),请先切换旧的 Ruby 版本再进行编译,

查看的自己 ruby 版本

$ ruby -v

ruby 2.3.3p222

切换 ruby 版本

2.3.3

$ rvm install 2.3.3 --disable-binary
$ rvm use 2.3.3 --default 

使用方法

  1. 切换 ruby 版本 小于 2.4.0

  2. iOSAutoArchiveScript 文件夹 拖入到项目 主目录!

  3. 打开 iOSAutoArchiveScript.sh 文件,修改 项目自定义部分参数,一般只需要修改两个参数 scheme_namebuild_configuration

  4. 打开终端, cd 到 iOSAutoArchiveScript文件夹,运行脚本

     $ sh iOSAutoArchiveScript.sh
    

最终会在桌面生成:

上传到 Fir

添加了将ipa包上传到 Fir 的功能

要使用fir的上传功能,需要安装fir的命令行工具

gem install fir-cli

修改配置

is_fir="true"
fir_token="FirAPIToken"

FirAPIToken官网获取

这样,导出 ipa包 成功时,就能顺带上传到 fir 了。

利用 自定义终端指令 简化打包过程

以zsh为例:

open ~/.zshrc

添加自定义命令 cd + sh

alias mybuild='cd 项目地址/iOSAutoArchiveScript/ &&  sh 项目地址/iOSAutoArchiveScript/iOSAutoArchiveScript.sh'

这样打开终端输入mybuild,就可以轻松实现一键打包上传了

LICENSE

MIT License

iosautoarchivescript's People

Contributors

qiubaiying avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.