I solved that problem by setting the Command Line Tools in Xcode. Go to:
Xcode > Preferences > Locations
And select the command line tool from the dropdown. If you have only one version of Xcode installed, there should be only one option. If you have several versions of Xcode, then you must choose the one you need.
Update (added image for reference)
sudo xcode-select -s /Applications/Xcode.app/Contents/Developer
(this should be path to your Xcode.app)
By the way this can happen even if you have only one version of Xcode . It happens when you instal homebrew
before the first Xcode installation (which makes sense because you may want to install Xcode through mas install 497799835
and mas
needs homebrew
).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With