[Zope-dev] Re: copyzopeskel.py patch

Tres Seaver tseaver at palladion.com
Thu May 12 16:01:51 EDT 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Dale Hirt wrote:

> Wonderful product, more than appreciate all the hard work that has
> been put into Zope and all the various products that are out there.
> 
> Came across a small issue, and wrote a quick patch for it. Didn't
> know who to send it to, so I thought I'd send it here.

Next time, you might file a collector issue at:

  http://www.zope.org/Collectors/Zope/

> When creating a new zope instance, using mkzopeinstance.py, and
> having my files under Subversion, copyzopeskel.py also took across my .svn
> directories. So I created the small patch below to stop that. Makes it a
> little more flexible for adding in new types, and since you've switched
> to Subversion anyways, makes sense to add it in there.
> 
> Again, thanks for your time,
> 
> Dale Hirt
> 
> 
> Index: copyzopeskel.py
> ===================================================================
> --- copyzopeskel.py	(revision 30342)
> +++ copyzopeskel.py	(working copy)
> @@ -186,12 +186,12 @@
>          print >>sys.stderr, msg
>          sys.exit(1)
>  
> -CVS = os.path.normcase("CVS")
> +CVS_DIRS = [os.path.normcase("CVS"), os.path.normcase(".svn")]
>  
>  def copydir((targetdir, replacements, uid, gid), sourcedir, names):
>      # Don't recurse into CVS directories:
>      for name in names[:]:
> -        if os.path.normcase(name) == CVS:
> +        if os.path.normcase(name) in CVS_DIRS:
>              names.remove(name)
>          elif os.path.isfile(os.path.join(sourcedir, name)):
>              # Copy the file:

Thanks for the patch.  I have checked it in for the next release.

Tres.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.5 (GNU/Linux)
Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org

iD8DBQFCg7Yu+gerLs4ltQ4RAt1gAJsGpLnVpT884gBe3QVsBfD9mIboAACeOx/y
QcSCnRtE3e67r32TJ5Bl1lU=
=QsNS
-----END PGP SIGNATURE-----



More information about the Zope-Dev mailing list