Don’t write long scripts on Jenkins or any other continuous integration system for your iOS builds. Xcode schemes give you lots of power to control your configurations and also give you space to write your project specific and scheme specific scripts. If you didn’t glance at my writings about build configurations and custom schemes. Check them out before continue reading: Build Configuration and Custom Schemes and Xcode Command Line Tools and Automated Builds
If you read previous articles on custom schemes, you’ve already realized that you don’t have to write scripts for all build variables. Special config files (.xcconfig extension files) do the duty for you.