I recently upgraded my Mac to Catalina.
Git broke with an error:
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
If you are in the same boat, read on to learn what solved this problem for me.
As with the Mojave upgrade, the Catalina upgrade also demands that I update Xcode tools. So I ran:
xcode-select — install
That prompted me to install command line tools that were mentioned in the previous error message.
But that surprisingly failed with another error.
So I downloaded Xcode (version 12) tools a different way. I think there are at least a few ways to accomplish this.
- Follow this link to download Xcode 12 command line tools from Apple. That’s what I did.
- In a web browser, go to the Apple Developer Downloads page, click on Applications, and download Xcode 12.
- Open the App Store on your Mac, search for “xcode”, then download and install Xcode developer tools.
After installing Xcode tools, Git once again works!
I’m sharing my experience in hopes that it helps someone else out there. This time was slightly more of a challenge than most pages cover.
Thanks for reading!