【发布时间】:2017-03-13 15:09:33
【问题描述】:
我一直在寻找一种使用 Xcodebuild 和 shell 脚本导出 IPA 的方法,我发现的只是旧代码,甚至 XCodebuild 错误对我来说都无法理解。请如果有人尝试过这样做并找到了解决方案,那将是很棒且有帮助的
PS:其实我已经找到了这个脚本来生成 IPA 的解决方案
这是我的密码
xcodebuild clean -workspace "${WORKSPACE_ABSOLUT_PATH}" -scheme "${SHEME_NAME}" -configuration Release
###Cleaning XCodeproj(Without Pods)
xcodebuild clean -project "${PROJECT_ABSOLUT_PATH}" -scheme "${SHEME_NAME}" -configuration Release
####Setting (Prod) Boolean value
#echo -n "" >"${PLIST_CONFIGURATION_NAME}"
##
#echo "Prod boolean value is $8"
##
#echo "<?xml version="1.0" encoding="UTF-8"?><!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"><plist version="1.0"><dict><key>Prod</key><${PROD_BOOLEAN_VALUE}/></dict></plist>" >> "${PLIST_CONFIGURATION_NAME}"
##
#head "${PLIST_CONFIGURATION_NAME}"
#
#
###Preparing Archive (Generate .xcarchive file)
##
xcodebuild archive -workspace "${WORKSPACE_ABSOLUT_PATH}" -scheme "${SHEME_NAME}" -archivePath "${ARCHIVE_ABSOLUT_PATH}"
##
#
##Export Archive file (.xcarchive) to (.ipa) file
#
xcodebuild -exportArchive -archivePath "${ARCHIVE_ABSOLUT_PATH}" -exportPath "${IPA_ABSOLUT_EXPORT_PATH}" -exportFormat ipa -exportProvisioningProfile "${PROVISIONING_PROFILE_NAME}"
【问题讨论】:
标签: ios shell provisioning-profile ipa xcodebuild