In my case, I had uninstalled Xcode and then issues with Git CLI started. I solved the problem running the following commands:
sudo xcode-select -r
sudo xcode-select --switch /Library/Developer/CommandLineTools
sudo xcode-select -r
sudo xcode-select --switch /Library/Developer/CommandLineTools
And then validating a new path with:
sudo xcode-select -p
sudo xcode-select -p