Jenkins不支持keychain解决方案

尝试jenkiins插件的时候,测试发现新版jenkins通过上传keychina无响应
于是采用脚本方式查找:

# 存储路径
cd /Users/wahaha/.jenkins/workspace/wahahaIos_ipa/ios
#pwd

 
rm -rf *.Adhoc.ipa


 
LOGIN_KEYCHAIN=~/Library/Keychains/login.keychain-db
# 用户密码
LOGIN_PASSWORD=wahaha123456

PackageName=wahaha_learn${BUILD_TIMESTAMP}.ipa 

pod setup
 
pod install


 
security unlock-keychain -p ${LOGIN_PASSWORD} ${LOGIN_KEYCHAIN}
 
xcodebuild clean -workspace Runner.xcworkspace  -scheme Runner
 
xcodebuild -archivePath Runner.xcarchive   -workspace Runner.xcworkspace -sdk iphoneos -scheme Runner -configuration ${BUILD_TYPE} archive 
 
xcodebuild -exportArchive -exportOptionsPlist /Users/wahaha/.jenkins/workspace/ExportOptions.plist   -archivePath Runner.xcarchive -exportPath  Runner_Test${BUILD_TIMESTAMP}.Adhoc.ipa

推荐阅读更多精彩内容