Beispiel #1
0
    def diff(self, other):
        diff = Metadata.diff(self, other)
        rdiff = RepomdDiff(diff)

        if not self.revision.isdigit() and not other.revision.isdigit():
            # Revision compare only if there are not numbers
            # Most of the time, revision is just a timestamp (number)
            # But in some cases (with --revision param) it could be any text
            if self.revision != other.revision:
                rdiff.revisions = (self.revision, other.revision)

        if self.tags != other.tags:
            rdiff.tags = (self.tags, other.tags)

        if rdiff:
            return rdiff
        return None
Beispiel #2
0
 def __init__(self, *args, **kwargs):
     Metadata.__init__(self, *args, **kwargs)
     self.tags = {}
     self.revision = ""
Beispiel #3
0
 def __init__(self, *args, **kwargs):
     Metadata.__init__(self, *args, **kwargs)