cocoapods 问题记录

. pod update warning Insecure world writable mode 040777

在利用命令行操作CocoaPods时,可能会遇到这样的 warning: Insecure world writable dir xxxxx in PATH, mode 040777,但是却又不妨碍使用。

提示含义: 目录被赋予777的权限,不安全。
如何解决:将提示权限改为775,问题即可解决。

具体实现:
在终端写入下列命令行,即可消除上面的提示。xxxxx 是 warning 中提示的文件路径
sudo chmod go-w xxxxx
sudo chmod 775 xxxxx

. You don't have write permissions for the /Library/Ruby/Gems/2.0.0 directory

使用命令 sudo gem install cocoapods 安装 cocoapods,仍然提示没有权限,
可以使用 sudo gem install -n /usr/local/bin cocoapods

[!] Authentication token is invalid or unverified. Either verify it with the email that was sent or register a new session.

解决方法:使用下面的命令重新注册,完成后会提示你到邮件中进行验证,点击一下邮件中的链接即可。然后就可以继续提交你的 pod 了

pod trunk register yourEmail@example.com 'Your Name'

- ERROR | [iOS] unknown: Encountered an unknown error (Could not find aiossimulator (valid values: ). Ensure that Xcode -> Window -> Devices has at least oneiossimulator listed or otherwise add one.) during validation.

解决方法:使用下面的命令更新 cocoapods。我是 XCode 11.1 出现的这个问题。

sudo gem update cocoapods

如果上面的命令不行,依次执行下面 3 个命令

sudo gem uninstall fourflusher
sudo gem install fourflusher
sudo gem update cocoapods
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容