编译命令

xcodebuild -workspace YourWorkSpaceName.xcworkspace -scheme YourProjectName SYMROOT=$(PWD)/build`

Archive命令

xcodebuild -workspace YourWorkSpaceName.xcworkspace -scheme YourProjectName archive -archivePath ~/Desktop/ShareJobStudent.xcarchive

打包IPA命令

xcodebuild -exportArchive -exportFormat ipa -archivePath ~/Desktop/YourProjectName.xcarchive -exportPath ~/Desktop/IPAName.ipa