8

I just upgraded my (Intel based) MacBookPro to macOS Mojave and now when typing git pull in a (Bash) shell, I now get the message:

xcrun: error invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun

It looks like there is an xcrun in a Homebrew directory.

Do I need to add something to my PATH?

0

2 Answers 2

10

xcrun is a tool that helps managing Xcode versions on your system. It allows you to write scripts that don't need to know where your Xcode instance or developer tools are installed.

The path to the Xcode version (or developer tools) is set/read via xcode-select. You can reset it via:

sudo xcode-select --reset

You can download the command line tools (that you're going to need if you don't have a full Xcode installed) via:

xcode-select --install

Or if you have Xcode installed, select it:

sudo xcode-select --switch <path_to_Xcode.app>
1

I'm hoping the answer linked below helps, i.e.

xcode-select --install

updating OS requires updating xcode

(It did.)

Not the answer you're looking for? Browse other questions tagged .