简体   繁体   English

当安装pod时,ERROR“无效的`Podfile`文件:未定义的方法`plateform'

[英]when install pod ,ERROR "Invalid `Podfile` file: undefined method `plateform'

I'am a new ios develper, I need to install 'AFNetworking'. 我是一个新的ios开发者,我需要安装'AFNetworking'。

first, i have installed cocoapods; 首先,我安装了cocoapods;

second, i created a 'Podfile' in my wordspace; 第二,我在我的文字空间中创建了一个'Podfile';

source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '8.0'
pod 'AFNetworking'

then, i run pod install There is a ERROR: 然后,我运行pod install有一个错误:

/System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/pathname.rb:422:in `open': No such file or directory - /Users/nemo/.cocoapods/repos (Errno::ENOENT)
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/pathname.rb:422:in `foreach'
from /System/Library/Frameworks/Ruby.framework/Versions/2.0/usr/lib/ruby/2.0.0/pathname.rb:422:in `children'
from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.35.0/lib/cocoapods/sources_manager.rb:63:in `all'
from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.35.0/lib/cocoapods/user_interface/error_report.rb:130:in `repo_information'
from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.35.0/lib/cocoapods/user_interface/error_report.rb:34:in `report'
from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.35.0/lib/cocoapods/command.rb:58:in `report_error'
from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:300:in `handle_exception'
from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:274:in `rescue in run'
from /Library/Ruby/Gems/2.0.0/gems/claide-0.7.0/lib/claide/command.rb:264:in `run'
from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.35.0/lib/cocoapods/command.rb:45:in `run'
from /Library/Ruby/Gems/2.0.0/gems/cocoapods-0.35.0/bin/pod:43:in `<top (required)>'
from /usr/bin/pod:23:in `load'
from /usr/bin/pod:23:in `<main>'

It would appear as though CocoaPods was not properly installed on your system. 看起来好像CocoaPods没有正确安装在您的系统上。

Take a look at this response: 看看这个回复:

Cocoapods commands fail due to "No such file or directory @ dir_initialize - /Users/<username>/.cocoapods/repos (Errno::ENOENT)" 由于“没有这样的文件或目录@dir_initialize - /Users/<username>/.cocoapods/repos(Errno :: ENOENT)”,Cocoapods命令失败

Try "pod setup" and then "pod install". 尝试“pod setup”然后“pod install”。

Second row: plateform :ios, '8.0' is misspelled. 第二排:平台plateform :ios, '8.0'拼写错误。 Should be: platform :ios, '8.0' 应该是: platform :ios, '8.0'

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 尝试运行Pod安装时出现错误“无效的Podfile文件:未知的regexp选项-jackha。” - Error “Invalid `Podfile` file: unknown regexp options - jackha.” when trying to run pod install 无效的“Podfile”文件:未定义的方法“use_native_modules!” 为了 #<pod::podfile:0x007fd5795662a0></pod::podfile:0x007fd5795662a0> - Invalid `Podfile` file: undefined method `use_native_modules!' for #<Pod::Podfile:0x007fd5795662a0> 容器安装失败,并显示以下错误:在iOS中安装容器时,“容器文件(来自`../`)`由`Podfile`所需要 - pod install failed with error: Library (from `../`)` required by `Podfile` when pod install in iOS React Native - iOS - 无效的`Podfile`文件:未定义的方法`[]'为nil:NilClass - React Native - iOS - Invalid `Podfile` file: undefined method `[]' for nil:NilClass 安装Firebase Pod错误无效Podfile - Installing Firebase pod error Invalid Podfile 执行“pod install”时出现Podfile错误? - Podfile error while doing “pod install”? “Podfile”文件语法错误无效,意外$ undefined,期待&#39;}&#39; - Invalid 'Podfile' file syntax error, unexpected $undefined, expecting '}' Flutter Pod 安装失败 - '无效的 `Podfile` 文件没有将 nil 隐式转换为字符串 - Flutter Pod install failed - 'Invalid `Podfile` file no implicit conversion of nil into String 在Pod安装/更新时无法解析Podfile.lock错误 - Unable to parse Podfile.lock error on Pod install/update 当我在控制台中引入pod install时,错误(NoMethodError - 未定义的方法`to_ary&#39;用于# <Pod::Specification name=“Parse”> )出现 - When I introduced pod install in console, the error (NoMethodError - undefined method `to_ary' for #<Pod::Specification name=“Parse”>) appears
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM