xxxxxxxxxx
#You can use only the !git row but This is the complete preffered code
import sys
import shutil
shutil.rmtree(<your repository name>,ignore_errors=True) #This will remove the directory if it is already cloned
!git clone https://git_token@github.com/repository.git
SourceCodePath2 = <your repository name>
sys.path.insert(2, SourceCodePath2 ) #This will make sure that colab will search your new directory when using import