-bash: /usr/local/bin/pod: /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/bin/ruby: b...

升级Mac OS 到 10.15.4后使用pod install命令报错如下:

-bash: /usr/local/bin/pod: /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/bin/ruby: bad interpreter: No such file or directory

解决执行命令如下(亲测可以):

brew link --overwrite cocoapods

原因是升级系统后默认ruby版本号升为2.6,原有cocoapod仍在调用2.3版本的ruby,找不到执行问题件导致,上面命令应该是重新做了关联

仍然不行则先执行

brew reinstall cocoapods

然后再执行

brew link --overwrite cocoapods

参考文章:

https://www.jianshu.com/p/dbd4d1417603

你可能感兴趣的:(-bash: /usr/local/bin/pod: /System/Library/Frameworks/Ruby.framework/Versions/2.3/usr/bin/ruby: b...)