CocoaPods Support
AppCode comes with the support for CocoaPods - an Objective-C library dependency manager. CocoaPods resolves dependencies between the various libraries you use and fetches the source code for the dependencies, thus helping you overcome most of the issues associated with using third party libraries.
With AppCode you can perform CocoaPods operations from the menu or context menu in the editor, when a pod file is opened.
On this page:
Prerequisites
In order to proceed with CocoaPods, you should have the Command Line Tools for Xcode installed. Open Xcode, from the main menu navigate to Command Line Tools and click on either Install or Update.
. Then selectCocoaPods gem operations
To install CocoaPods gem
On the main menu, choose
To view available pods and their description
On the main menu, choose
The available pods are listed in the right pane. Scroll down to see all pods, and click on a selected pod to view its description which will be displayed in the lower pane.
To update CocoaPods gem
On the main menu, choose Update CocoaPods
and click
To update CocoaPods local repositories
On the main menu, choose Update Repositories
and click
Podfile operations
To create a Podfile
On the main menu, choose
To open an existing Podfile
On the main menu, choose
To install a pod, do one of the following
On the main menu, choose
If the Podfile is opened, from the context menu in the editor, choose
To update a pod, do one of the following
On the main menu, choose
If the Podfile is opened, from the context menu in the editor, choose
Podfile coding assistance
While working on a Podfile content, you can take advantage of the following coding assistance features:
Syntax highlighting and error detection.
- Completion of:
key functions names (pod, target, podspec, etc.)
pod arguments (names and versions of available pods)
target argument (names of available targets)
platform arguments (names and versions of available platforms)
- On-the-fly inspections. AppCode warns you whenever it detects:
pods defined in the Podfile but not installed
pods installed but not defined in the Podfile
installed version of the pod differs from the version described in the Podfile
unknown pod (pod "ThereIsNoSuchPod")
unknown or invalid pod version in the Podfile
locally installed pods versions do match the description in the Manifest.lockfile
new version of a pod available. (Look at the right gutter for a notification, or press ⌘+F1 with the caret on the pod name)
Quick fixes can be applied in some cases. (Press ⌥⏎.)