Last night i updated to macOS Mojave,
This morning I navigated to my work's code base in Command line on my MacBook pro,
typed in "git status" in the repo and received the error:
xcrun: error: invalid active developer path (/Library/Developer/CommandLineTools), missing xcrun at: /Library/Developer/CommandLineTools/usr/bin/xcrun
In addition to dustbuster's answer I needed to set path to the Xcode folder with this command:
Take it be easy