[Checkins] SVN: zc.recipe.zope3instance/branches/gocept-zconf-slug-dev/src/zc/recipe/zope3instance/__init__.py complaining if both "foo" and "foo.in" exist in instance after merging skeletons but before interpolating "foo.in" to "foo"

Christian Zagrodnick cz at gocept.com
Wed Dec 20 03:56:17 EST 2006


Log message for revision 71613:
  complaining if both "foo" and "foo.in" exist in instance after merging skeletons but before interpolating "foo.in" to "foo"

Changed:
  U   zc.recipe.zope3instance/branches/gocept-zconf-slug-dev/src/zc/recipe/zope3instance/__init__.py

-=-
Modified: zc.recipe.zope3instance/branches/gocept-zconf-slug-dev/src/zc/recipe/zope3instance/__init__.py
===================================================================
--- zc.recipe.zope3instance/branches/gocept-zconf-slug-dev/src/zc/recipe/zope3instance/__init__.py	2006-12-20 07:37:49 UTC (rev 71612)
+++ zc.recipe.zope3instance/branches/gocept-zconf-slug-dev/src/zc/recipe/zope3instance/__init__.py	2006-12-20 08:56:16 UTC (rev 71613)
@@ -178,6 +178,9 @@
                 continue
 
             new_name = os.path.join(dest, name[:-3])
+            if os.path.exists(new_name):
+                raise zc.buildout.UserError("There are both %r and %r." % (
+                    name, new_name))
 
             old_contents = file(in_file, 'r').read()
             new_contents = old_contents % options



More information about the Checkins mailing list