<div dir="ltr"><br><br><br><div class="gmail_quote"><div dir="ltr">On Wed, 7 Nov 2018 at 13:11, Vijay Kumar Banerjee <<a href="mailto:vijaykumar9597@gmail.com">vijaykumar9597@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">---<br>
rtemstoolkit/path.py | 5 +++--<br>
1 file changed, 3 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/rtemstoolkit/path.py b/rtemstoolkit/path.py<br>
index 760f4bd..83fb361 100644<br>
--- a/rtemstoolkit/path.py<br>
+++ b/rtemstoolkit/path.py<br>
@@ -191,10 +191,11 @@ def copy_tree(src, dst):<br>
hsrc = host(src)<br>
hdst = host(dst)<br>
<br>
- if os.path.exists(src):<br>
+ if os.path.exists(src) and os.path.isdir(src):<br>
names = os.listdir(src)<br>
else:<br>
- name = []<br>
+ names = [basename(src)]<br>
+ src = dirname(src)<br>
<br>
if not os.path.isdir(dst):<br>
os.makedirs(dst)<br>
-- <br>
2.17.2<br></blockquote><div>ping :) </div></div></div>