getgitspace / clone_repo.py
Samarth Naik
hf p1
0c87788
raw
history blame contribute delete
225 Bytes
import os
from git import Repo
def clone_repo(github_url, dest_folder='source_repo'):
if os.path.exists(dest_folder):
import shutil
shutil.rmtree(dest_folder)
Repo.clone_from(github_url, dest_folder)