CocoaPod 使用

一、建立PodFile文件:终端进入工程目录,touch Podfile ;ios

二、编辑PodFile文件:终端输入  vim Podfile  ;vim

platform:ios, ‘7.0’
target 'iCarouselTest' do
pod 'iCarousel', '~> 1.8.2'
end code

三、ESC、“:”、wq 退出vim编辑;orm

四、终端输入: pod install get

 

常见问题:it

一、执行pod install 或pod update 命令后,updating local specsrepositories 卡住不动io

解决办法:pod install 被墙了,换成新的命令pod install --verbose --no-repo-updateform

二、报错:Your Podfile has had smart quotes sanitisedsed

解决办法:不要使用文本编辑去编辑Podfile,使用Xcode编辑,或者使用终端敲命令去编辑。(3)date

三、项目运行时报错:Thefile “Pods.xcconfig” couldn’t be opened because there is no such file.

解决办法:pod update就能够了。

相关文章
相关标签/搜索