ios打包及部署命令
|
|
- 指定Xcode版本(最新代码需用xcode8编译)
- 编译xxxx的代码,生成xcarchive文件
- 在工程根目录下新建一个ouputIPA文件夹
- 对xccharive进行代码签名和打包,生成对应的ipa文件,名称为xxxx_buildnumber,
其中buildnumber为构建编号,以区分每一次构建的包 - 把ipa文件拷贝到outIPA下,并重命名为xxxx.ipa
把xxxx.ipa上传(可将这一步抽出,单独建立一个任务)
Android打包及部署命令
12345678910111213141516171819202122cd xxxx${WORKSPACE}/../../common_shell/dir.sh ${WORKSPACE}/xxxx/app/apk_backupecho "ARCHIVE_TYPE"= ${ARCHIVE_TYPE}if [ "${ARCHIVE_TYPE}" == "1" ]; then./gradlew clean./gradlew assAAAADefult000000Release --stacktrace\cp ${WORKSPACE}/xxxx/app/build/outputs/apk/AAAAA_release.apk ${WORKSPACE}/xxxx/app/apk_backupAAAA_release_${BUILD_NUMBER}.apk./gradlew clean./gradlew assxxxxRelease --stacktrace\cp ${WORKSPACE}/xxxx/app/build/outputs/apk/xxxx_release.apk ${WORKSPACE}/xxxx/app/apk_backup/xxxx_release_${BUILD_NUMBER}.apkelse./gradlew clean./gradlew assAAAAADefult000000Tice --stacktrace\cp ${WORKSPACE}/xxxx/app/build/outputs/apk/app-AAAAA-defult000000-tice.apk ${WORKSPACE}/juanpi/app/apk_backup/AAAAA_tice_${BUILD_NUMBER}.apk./gradlew clean./gradlew assxxxxDefult000000Tice --stacktrace\cp ${WORKSPACE}/xxxx/app/build/outputs/apk/app-xxxx-defult000000-tice.apk ${WORKSPACE}/xxxx/app/apk_backup/xxxx_tice_${BUILD_NUMBER}.apkfi切换到xxxx目录下,这是安卓的主工程目录
- 在xxxx/app目录下新建一个apk_backup文件夹
- 清除之前打包生成的文件
- 打包xxxx代码,生成xxxxDefault00000Tice.apk文件
- 把xxxxDefault00000Tice.apk拷贝到apk_backup文件夹下
- 同理,目标换成AAAAA的代码
邮件通知
当构建失败时,会发邮件通知到git 提交记录对应的人,这里也可以配置其他人。邮件的服务器、帐号、密码、后缀等信息在系统设置面板中配置