podfile in xcode code example Example 1: cocoa pods $ sudo gem install cocoapods Example 2: open podfile in xcode from terminal $ open -a XCode Podfile