(self)
Prune off branches that might slip into the file list as created
        by 'read_template()', but really don't belong there:
          * 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, .svn, .hg, .git, .bzr, _darcs directories
Prune off branches that might slip into the file list as created
        by 'read_template()', but really don't belong there:
          * 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, .svn, .hg, .git, .bzr, _darcs directories
Prune off branches that might slip into the file list as created by read_template () but really don t belong there : * 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 . svn . hg . git . bzr _darcs directories
def prune_file_list(self):
        """Prune off branches that might slip into the file list as created
        by 'read_template()', but really don't belong there:
          * 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, .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)

        if sys.platform == 'win32':
            seps = r'/|\\'
        else:
            seps = '/'

        vcs_dirs = ['RCS', 'CVS', r'\.svn', r'\.hg', r'\.git', r'\.bzr',
                    '_darcs']
        vcs_ptrn = r'(^|%s)(%s)(%s).*' % (seps, '|'.join(vcs_dirs), seps)
        self.filelist.exclude_pattern(vcs_ptrn, is_regex=1)
def prune_file_list ( self ) : 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 ) if sys . platform == 'win32' : seps = r'/|\\' else : seps = '/' vcs_dirs = [ 'RCS' , 'CVS' , r'\.svn' , r'\.hg' , r'\.git' , r'\.bzr' , '_darcs' ] vcs_ptrn = r'(^|%s)(%s)(%s).*' % ( seps , '|' . join ( vcs_dirs ) , seps ) self . filelist . exclude_pattern ( vcs_ptrn , is_regex = 1 )