~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/commit.py

  • Committer: Robert Collins
  • Date: 2006-03-01 08:40:35 UTC
  • mto: (1594.2.4 integration)
  • mto: This revision was merged to the branch mainline in revision 1596.
  • Revision ID: robertc@robertcollins.net-20060301084035-ce00abd11fe4da31
Change weave store to be a versioned store, using WeaveFiles which maintain integrity without needing explicit 'put' operations.

Show diffs side-by-side

added added

removed removed

Lines of Context:
92
92
from bzrlib.xml5 import serializer_v5
93
93
from bzrlib.inventory import Inventory, ROOT_ID
94
94
from bzrlib.symbol_versioning import *
95
 
from bzrlib.weave import Weave
96
 
from bzrlib.weavefile import read_weave, write_weave_v5
97
95
from bzrlib.workingtree import WorkingTree
98
96
 
99
97
 
321
319
        inv_text = serializer_v5.write_inventory_to_string(self.new_inv)
322
320
        self.inv_sha1 = sha_string(inv_text)
323
321
        s = self.branch.repository.control_weaves
324
 
        s.add_text('inventory', self.rev_id,
325
 
                   split_lines(inv_text), self.present_parents,
326
 
                   self.branch.get_transaction())
 
322
        inv_versioned_file = s.get_weave('inventory',
 
323
                                         self.branch.repository.get_transaction())
 
324
        inv_versioned_file.add_lines(self.rev_id,
 
325
                                     self.present_parents,
 
326
                                     split_lines(inv_text))
327
327
 
328
328
    def _escape_commit_message(self):
329
329
        """Replace xml-incompatible control characters."""