MCPcopy Create free account
hub / github.com/RT-Thread/rt-thread / do_copy_folder

Function do_copy_folder

tools/mkdist.py:45–58  ·  view source on GitHub ↗
(src_dir, dst_dir, ignore=None)

Source from the content-addressed store, hash-verified

43 shutil.copy2(src, dst)
44
45def do_copy_folder(src_dir, dst_dir, ignore=None):
46 import shutil
47 # check source directory
48 if not os.path.exists(src_dir):
49 return
50
51 try:
52 if os.path.exists(dst_dir):
53 shutil.rmtree(dst_dir)
54 except:
55 print('Deletes folder: %s failed.' % dst_dir)
56 return
57
58 shutil.copytree(src_dir, dst_dir, ignore = ignore)
59
60source_ext = ['c', 'h', 's', 'S', 'cpp', 'cxx', 'cc', 'xpm']
61source_list = []

Callers 2

bsp_copy_filesFunction · 0.85
MkDistFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected