在 Xcode 项目中安装 pod 时,我遇到如下 Podfile 问题。
Invalid Podfile
文件:未定义的方法“存在吗?”对于文件:类
我确实尝试过更新 pod 版本brew upgrade cocoapods
并点击以下链接:
https://dev.to/retyui/fix-a-pod-install-error-undefined-method-exist-for-fileclass-react-native-24ke https://dev.to/retyui/fix-a-pod-install-error-undefined-method-exist-for-fileclass-react-native-24ke
但仍然没有解决。
请指导我在这里做错了什么。
下面是我的 Podfile:
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'
flutter_application_path = '../bmi_flutter'
load File.join(flutter_application_path, '.ios', 'Flutter', 'podhelper.rb')
target 'MixedNativeApp' do
# Comment the next line if you don't want to use dynamic frameworks
use_frameworks!
install_all_flutter_pods(flutter_application_path)
# Pods for MixedNativeApp
target 'MixedNativeAppTests' do
inherit! :search_paths
# Pods for testing
end
target 'MixedNativeAppUITests' do
# Pods for testing
end
end
这是我对上述问题的解决方案(发布是否对处于相同情况的开发人员有帮助)
gem cleanup
brew uninstall cocoapods
sudo gem uninstall cocoapods
sudo gem install cocoapods -v 1.10.0 -n /usr/local/bin ***`add cocoapod version u want to install`***
sudo gem install cocoapods-user-defined-build-types
pod install --repo-update
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)