[Python-checkins] r61268 - in python/branches/release25-maint: Doc/dist/dist.tex Lib/distutils/command/sdist.py Misc/NEWS

martin.v.loewis python-checkins at python.org
Thu Mar 6 08:14:27 CET 2008


Author: martin.v.loewis
Date: Thu Mar  6 08:14:26 2008
New Revision: 61268

Modified:
   python/branches/release25-maint/Doc/dist/dist.tex
   python/branches/release25-maint/Lib/distutils/command/sdist.py
   python/branches/release25-maint/Misc/NEWS
Log:
Backport of r61263:
#1725737: ignore other VC directories other than CVS and SVN's too.


Modified: python/branches/release25-maint/Doc/dist/dist.tex
==============================================================================
--- python/branches/release25-maint/Doc/dist/dist.tex	(original)
+++ python/branches/release25-maint/Doc/dist/dist.tex	Thu Mar  6 08:14:26 2008
@@ -1213,7 +1213,8 @@
 be included in the source distribution:
 \begin{itemize}
 \item all files in the Distutils ``build'' tree (default \file{build/})
-\item all files in directories named \file{RCS}, \file{CVS} or \file{.svn}
+\item all files in directories named \file{RCS}, \file{CVS}, \file{.svn},
+      \file{.hg}, \file{.git}, \file{.bzr}, or \file{\_darcs}
 \end{itemize}
 Now we have our complete list of files, which is written to the manifest
 for future reference, and then used to build the source distribution
@@ -1246,7 +1247,8 @@
   \code{prune} command in the manifest template comes after the
   \code{recursive-include} command
 \item exclude the entire \file{build} tree, and any \file{RCS},
-  \file{CVS} and \file{.svn} directories
+  \file{CVS}, \file{.svn}, \file{.hg}, \file{.git}, \file{.bzr}, or
+  \file{\_darcs} directories
 \end{enumerate}
 Just like in the setup script, file and directory names in the manifest
 template should always be slash-separated; the Distutils will take care

Modified: python/branches/release25-maint/Lib/distutils/command/sdist.py
==============================================================================
--- python/branches/release25-maint/Lib/distutils/command/sdist.py	(original)
+++ python/branches/release25-maint/Lib/distutils/command/sdist.py	Thu Mar  6 08:14:26 2008
@@ -347,14 +347,14 @@
           * the build tree (typically "build")
           * the release tree itself (only an issue if we ran "sdist"
             previously with --keep-temp, or it aborted)
-          * any RCS, CVS and .svn directories
+          * any RCS, CVS, .svn, .hg, .git, .bzr, _darcs directories
         """
         build = self.get_finalized_command('build')
         base_dir = self.distribution.get_fullname()
 
         self.filelist.exclude_pattern(None, prefix=build.build_base)
         self.filelist.exclude_pattern(None, prefix=base_dir)
-        self.filelist.exclude_pattern(r'/(RCS|CVS|\.svn)/.*', is_regex=1)
+        self.filelist.exclude_pattern(r'(^|/)(RCS|CVS|\.svn|\.hg|\.git|\.bzr|_darcs)/.*', is_regex=1)
 
 
     def write_manifest (self):

Modified: python/branches/release25-maint/Misc/NEWS
==============================================================================
--- python/branches/release25-maint/Misc/NEWS	(original)
+++ python/branches/release25-maint/Misc/NEWS	Thu Mar  6 08:14:26 2008
@@ -15,6 +15,9 @@
 Library
 -------
 
+- Bug #1725737: In distutil's sdist, exclude RCS, CVS etc. also in the
+  root directory, and also exclude .hg, .git, .bzr, and _darcs.
+
 - Bug #1389051: imaplib causes excessive memory fragmentation when reading
   large messages.
 


More information about the Python-checkins mailing list