~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/xml5.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2006-04-06 10:41:03 UTC
  • mfrom: (1638.1.2 integration)
  • Revision ID: pqm@pqm.ubuntu.com-20060406104103-849a925941c89106
Change the basis-inventory file to not have the revision-id in the file name.

Show diffs side-by-side

added added

removed removed

Lines of Context:
35
35
        e.text = '\n'
36
36
        if inv.root.file_id not in (None, ROOT_ID):
37
37
            e.set('file_id', inv.root.file_id)
 
38
        if inv.revision_id is not None:
 
39
            e.set('revision_id', inv.revision_id)
38
40
        for path, ie in inv.iter_entries():
39
41
            e.append(self._pack_entry(ie))
40
42
        return e
121
123
            if format != '5':
122
124
                raise BzrError("invalid format version %r on inventory"
123
125
                                % format)
124
 
        inv = Inventory(root_id)
 
126
        revision_id = elt.get('revision_id')
 
127
        inv = Inventory(root_id, revision_id=revision_id)
125
128
        for e in elt:
126
129
            ie = self._unpack_entry(e)
127
130
            if ie.parent_id == ROOT_ID: