Add function to check if git is available.