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

def dbtexmf::dblatex::grubber::index::Index::run_needed (   self  ) 

Check if makeindex has to be run. This is the case either if the
target file does not exist or if the source file has changed.

Definition at line 162 of file index.py.

00162                          :
        """
        Check if makeindex has to be run. This is the case either if the
        target file does not exist or if the source file has changed.
        """
        if os.path.getsize(self.source) == 0:
            msg.log(_("the index file %s is empty") % self.source, pkg="index")
            return 0
        new = md5_file(self.source)
        if not os.path.exists(self.target):
            self.md5 = new
            return 1
        if not self.md5:
            self.md5 = new
            msg.log(_("the index file %s is new") % self.source, pkg="index")
            return 1
        if self.md5 == new:
            msg.log(_("the index %s did not change") % self.source, pkg="index")
            return 0
        self.md5 = new
        msg.log(_("the index %s has changed") % self.source, pkg="index")
        return 1

    def clean (self):


Generated by  Doxygen 1.6.0   Back to index