mirror of
https://git.rtems.org/rtems-tools/
synced 2025-10-16 20:18:12 +08:00
rtemstoolkit/path: Add support to copy single file
This commit is contained in:

committed by
Chris Johns

parent
29ad0ec7a8
commit
2852cac71a
@@ -314,8 +314,12 @@ def copy_tree(src, dst):
|
|||||||
hsrc = host(src)
|
hsrc = host(src)
|
||||||
hdst = host(dst)
|
hdst = host(dst)
|
||||||
|
|
||||||
if exists(src):
|
if exists(hsrc):
|
||||||
names = listdir(src)
|
if isdir(hsrc):
|
||||||
|
names = listdir(hsrc)
|
||||||
|
else:
|
||||||
|
names = [basename(hsrc)]
|
||||||
|
hsrc = dirname(hsrc)
|
||||||
else:
|
else:
|
||||||
names = []
|
names = []
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user