I recently upgraded to Mac OS Mojave and Git started throwing error: Invalid active developer path
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
It means that you need to install XCode command line, open a Terminal and run this command:
$ xcode-select — install
That’s it. You should be good now