
解压环境变量打开配置文件open ~/.bash_profile添加变量export PATH=/Users/用户名/documents/Flutter/Flutter/bin:$PATH使环境变量生效source ~/.bash_profile健康检测Flutter doctorpixiao@192 Desktop % Flutter doctorDoctor summary (to see all details, run Flutter doctor -v):[✓] Flutter (Channel stable, 2.2.1, on Mac OS X 10.15.7 19H15 darwin-x64, locale zh-Hans-CN)[!] AndroID toolchain - develop for AndroID devices (AndroID SDK version 30.0.3) ! Some AndroID licenses not accepted. To resolve this, run: Flutter doctor --androID-licenses[✓] Xcode - develop for iOS and macOS[✓] Chrome - develop for the web[✓] AndroID Studio (version 4.2)[✓] IntelliJ IDEA ultimate Edition (version 2021.1)[✓] VS Code (version 1.55.1)[✓] Connected device (1 available)! Doctor found issues in 1 category.问题解决AndroID licenses全部接受Flutter doctor --androID-licenses# 然后一路 y 就可以了如果提示没有安装cocoapods### 方式一(推荐,版本是1.10.0以上的版本)# 安装brew install cocoapods# 卸载brew uninstall cocoapods# link# 根据提示进行强制link就可以了,具体的那个命令忘了,但是这个步骤是必须的!!!brew link cocoapods### 方式二# 安装sudo gem install cocoapods (这个命令我会报错,ruby有问题)sudo gem install cocoapods -v 1.8.4 (这个健康检测会提示版本较低)# 卸载sudo gem uninstall cocoapods完美状态@H_502_4@其他设置@H_502_4@其他设置请到Flutter中文网进行查看@H_502_4@Flutter中文网:https://flutterchina.club/get-started/install/ 总结
以上是内存溢出为你收集整理的Flutter Mac环境搭建全部内容,希望文章能够帮你解决Flutter Mac环境搭建所遇到的程序开发问题。
如果觉得内存溢出网站内容还不错,欢迎将内存溢出网站推荐给程序员好友。
欢迎分享,转载请注明来源:内存溢出
微信扫一扫
支付宝扫一扫
评论列表(0条)