1.cd 命令进入你要打包的包含xcodeproj的文件夹中
2.xcodebuild -project PC300.xcodeproj -target PC300 -configuration Release
3.xcrun -sdk iphoneos -v PackageApplication ./build/Release-iphoneos/PC300.app -o ~/Desktop/PC300.ipa
xcrun -sdk iphoneos -v xcodebuild -exportArchive ./build/Release-iphoneos/PC300.app -o ~/Desktop/PC300.ipa
xcodebuild archive -workspace PC300.xcworkspace -scheme PC300 -archivePath PC300.xcarchive
xcodebuild -exportArchive -archivePath PC300.xcarchive -exportPath PC300 -exportFormat ipa
记得provisioner别选错
脚本打包不只是这些,有需要的自行查阅资料