Flutter编译问题记录

问题:

运行出现以下报错

Launching lib/main.dart on macOS in debug mode... Warning: CocoaPods not installed. Skipping pod install. CocoaPods is a package manager for iOS or macOS platform code. Without CocoaPods, plugins will not work on iOS or macOS. For more info, see Using packages | Flutter For installation instructions, see CocoaPods Guides - Getting Started Error: CocoaPods not installed or not in valid state.

提示:应该是CocoaPods安装有问题

步骤:

1.先卸载所有的CocoaPods

  (1)查看 gem list cocoapods 或者 

gem list | grep cocoapods

 

或者which -a pod

或者

(2)卸载方式

brew uninstall cocoapods

或者

sudo gem uninstall cocoapods

或者

sudo rm -rf /usr/local/opt/ruby/bin/pod

或者

sudo rm -rf /usr/local/bin/pod

直到 which -a pod 为空

2.安装

sudo gem install -n /usr/local/bin cocoapods

pod setup

pod --version

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值