xcode-select active developer directory error

2019-01-02 21:17发布

Saw the following error when running an npm install which required node-gyp... but could be triggered by anything which requires xcode-select.

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

What is the problem?

13条回答
我只想做你的唯一
2楼-- · 2019-01-02 22:23

Other solution for those who don't want to install Xcode:

  1. Install Command Line Tools (if you haven't already):

    xcode-select --install

  2. Change the active directory:

    sudo xcode-select -switch /Library/Developer/CommandLineTools

This worked for me (git).

查看更多
登录 后发表回答