Logo Search packages:      
Sourcecode: tailor version File versions  Download package

def vcpx::darcs::DarcsWorkingDir::_adaptEntries (   self,
  changeset 
) [private]

Filter out boring files.

Definition at line 553 of file darcs.py.

00553                                       :
        """
        Filter out boring files.
        """

        from copy import copy

        adapted = SyncronizableTargetWorkingDir._adaptEntries(self, changeset)

        # If there are no entries or no rules, there's nothing to do
        if not adapted or not adapted.entries or not self.__unwanted_entries:
            return adapted

        entries = []
        skipped = False
        for e in adapted.entries:
            skip = False
            for rx in self.__unwanted_entries:
                if rx.search(e.name):
                    skip = True
                    break
            if skip:
                self.log.info('Entry "%s" skipped per boring rules', e.name)
                skipped = True
            else:
                entries.append(e)

        # All entries are gone, don't commit this changeset
        if not entries:
            self.log.info('All entries ignored, skipping whole '
                          'changeset "%s"', changeset.revision)
            return None

        if skipped:
            adapted = copy(adapted)
            adapted.entries = entries

        return adapted

    def _tag(self, tag):


Generated by  Doxygen 1.6.0   Back to index