[Checkins] SVN: zc.buildout/branches/dev/src/zc/buildout/easy_install.py Fixed egg copying code to overwite existing file, if necessary.

Jim Fulton jim at zope.com
Mon Dec 4 15:07:54 EST 2006


Log message for revision 71395:
  Fixed egg copying code to overwite existing file, if necessary.
  

Changed:
  U   zc.buildout/branches/dev/src/zc/buildout/easy_install.py

-=-
Modified: zc.buildout/branches/dev/src/zc/buildout/easy_install.py
===================================================================
--- zc.buildout/branches/dev/src/zc/buildout/easy_install.py	2006-12-04 20:01:32 UTC (rev 71394)
+++ zc.buildout/branches/dev/src/zc/buildout/easy_install.py	2006-12-04 20:07:53 UTC (rev 71395)
@@ -465,7 +465,7 @@
     for path in paths:
         if os.path.isdir(path):
             shutil.rmtree(path)
-        else:
+        elif os.path.exists(path):
             os.remove(path)
 
 def _copyeggs(src, dest, suffix, undo):
@@ -474,6 +474,7 @@
     for name in os.listdir(src):
         if name.endswith(suffix):
             new = os.path.join(dest, name)
+            _rm(new)
             os.rename(os.path.join(src, name), new)
             result.append(new)
 



More information about the Checkins mailing list