Regular iOS projects should work out of the box with Nevercode. However, there might be some extra hassle when it comes to Cocoapods projects.
Most iOS developers today use Cocoapods for dependency management. While it is an excellent tool, it can be a bit tricky to set up correctly, especially in a CI environment.
The two most common mistakes developers make when working with Pods are:
- selecting a non-workspace project
- not marking their schemes as shared
If your project is using Cocoapods, you must select the project name which ends with [workspace] in your build settings.
Selecting project ending with [workspace].
Similarly, the respective configuration name in the next drop-down must end with [scheme].
Schemes that are not marked as shared in Xcode cannot be built outside of your local Xcode environment. This will affect any CI server like Nevercode as well.
Let’s walk through the process of sharing a scheme:
Navigate to Product-> Scheme -> Manage Schemes
You will then be shown a list of schemes, each marked as being shared or not.
Make sure that the shared checkbox is selected next to your scheme, then click OK.
Finally, once you have marked the scheme as shared, you will have to add the new files generated by Xcode to your git repository as well. In Xcode,
- Navigate to Source Control > Commit.
- Select the Shared Data folder.
- Enter your commit message in the text field.
- Select the Push to remote option.
- Click the Commit Files button.
Alternatively, you can commit and push the changes from the command line.
To let Nevercode detect the changes, rescan your project. You will then be able to select the shared scheme from the Target drop-down menu.
Rescanning build configurations.