1.在终端运行:$ sudo gem install cocoa pods会出现以下错误:ERROR: While executing gem ... (Errno::EPERM)Operation not permitted - /usr/bin/xcodeproj2.解决方法:将其改成等待几秒即可:$ sudo gem install -n /usr/local/bin cocoapods