编译版本自增`agvtool new-version next -all`导致Xcode无故build cancel

在run Pre-actions新建脚本


image.png
cd ${PROJECT_DIR}
echo `pwd`
d_Project_Name="mx2app"
Pbxproj_Path="./${d_Project_Name}.xcodeproj/project.pbxproj"
buildNumber=$(date +%Y%m%d%H%M%S)
echo ${buildNumber}
#agvtool new-marketing-version ${buildNumber} 无故 build cancel
sed -i "" "s/CURRENT_PROJECT_VERSION = .*;/CURRENT_PROJECT_VERSION = ${buildNumber};/g" ${Pbxproj_Path}

你可能感兴趣的:(编译版本自增`agvtool new-version next -all`导致Xcode无故build cancel)