This project exists to make sense of some AppCode errors which occur when an Xcode workspace or project exists in a folder which contains a build.gradle file but that build.gradle is a module-level build.gradle file and not a root-level build.gradle file.
The trick to get it all to work is to follow these steps:
- Open the Xcode workspace or project in AppCode (in the case of this project, it's the iOS/AppCodeExperiment.xcodeproj file).
- Tap the
'Load Gradle Project'button in the'Gradle build scripts found'popup. - Observe the
Task 'wrapper' not found in project ':iOS'.error message in the Build window. - Navigate to AppCode's Gradle settings (you can get there via AppCode preferences or via the Gradle window).
- Observe the
'gradle-wrapper.properties' not founderror message. - Change the
'Use Gradle from'setting to'Specified location'. - Specify the location of Gradle on your machine if AppCode hasn't located it automatically (for me AppCode detects it at
/usr/local/Cellar/gradle/6.8.3/libexec). - Apply changes.
- Observe that the build now succeeds.