我在使用cocoa pods 的时候,出现下面的错误
[!] Invalid Podfile
file: undefined local variable or method `afnetworking' for #<Pod::Podfile:0x007fa6c11591f8>. Updating CocoaPods might fix the issue.
关键是我不管导入什么第三方库都会出现这个,一直都导不进去
profile里面我只是写了
pod ‘sdwebimage’
也没有用到afnetworking,ruby环境重新装,cocoa pods 更新什么的都试过了,连mac的系统都更新了,还是不行,,就是不行!!!
求个大神帮我看看怎么回事
The problem is not very clear. You can try to check your Podfile. The correct way is this:
Many people write their quotation marks like this
It’s best to use vim when editing files, give it a try. Be sure to follow the official format. For example:
Many people will add an extra space after:, which will also cause an error.
No, no matter what I enter, I get an error
[!] Invalid Podfile file: undefined local variable or method `afnetworking' for #<Pod::Podfile:0x007fa6c11591f8>. Updating CocoaPods might fix the issue.
The key point is that no matter whether I import any framework or not, I always get an error saying that afnetworking is not found. When I import other frameworks, such as sdwebimage, I always get an error saying that afnetworking is not found.
The afnetworking framework is not used, why do I always get an error and cannot find afnetworking?