美文网首页
xcode-select: error: tool 'xcode

xcode-select: error: tool 'xcode

作者: 一介书生独醉江湖 | 来源:发表于2020-05-29 18:00 被阅读0次

安装IOS真机时:

npm install -g  ios-deploy

错误:xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

1 删除xcode,重新安装
https://www.jianshu.com/writer#/notebooks/46062769/notes/70873701

2 查看xcodebuild路径

bogon:node_modules$ xcode-select --print-path
/Library/Developer/CommandLineTools

bogon:node_modules$ xcodebuild -showsdks
xcode-select: error: tool 'xcodebuild' requires Xcode, but active developer directory '/Library/Developer/CommandLineTools' is a command line tools instance

3 将xcodebuild路径切换到Xcode的目录下

sudo xcode-select --switch /Applications/Xcode.app/Contents/Developer/

参考:
https://www.jianshu.com/p/04033964f600

相关文章

网友评论

      本文标题:xcode-select: error: tool 'xcode

      本文链接:https://www.haomeiwen.com/subject/vzjfzhtx.html