首先需要安装ruby环境(参见http://www.cnblogs.com/stevenjiang/p/4936426.html)
$ sudo gem install cocoapods
参考资料:https://cocoapods.org/