/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/repository.py

  • Committer: Robert Collins
  • Date: 2007-09-11 09:09:40 UTC
  • mto: (2592.3.134 repository)
  • mto: This revision was merged to the branch mainline in revision 2879.
  • Revision ID: robertc@robertcollins.net-20070911090940-2lbw0h6ev8z2zp6w
Fixup various commit test failures falling out from the other commit changes.

Show diffs side-by-side

added added

removed removed

Lines of Context:
78
78
 
79
79
    _file_ids_altered_regex = lazy_regex.lazy_compile(
80
80
        r'file_id="(?P<file_id>[^"]+)"'
81
 
        r'.*revision="(?P<revision_id>[^"]+)"'
 
81
        r'.* revision="(?P<revision_id>[^"]+)"'
82
82
        )
83
83
 
84
84
    def abort_write_group(self):
2198
2198
                ' record_entry_contents, as of bzr 0.10.',
2199
2199
                 DeprecationWarning, stacklevel=2)
2200
2200
            self.record_entry_contents(tree.inventory.root.copy(), parent_invs,
2201
 
                                       '', tree)
 
2201
                                       '', tree, tree.path_content_summary(''))
2202
2202
        else:
2203
2203
            # In this revision format, root entries have no knit or weave When
2204
2204
            # serializing out to disk and back in root.revision is always
2218
2218
        :param tree: The tree which contains this entry and should be used to 
2219
2219
            obtain content.
2220
2220
        :param content_summary: Summary data from the tree about the paths
2221
 
            content - stat, length, exec, sha/link target.
 
2221
            content - stat, length, exec, sha/link target. This is only
 
2222
            accessed when the entry has a revision of None - that is when it is
 
2223
            a candidate to commit.
2222
2224
        """
2223
2225
        if self.new_inventory.root is None:
2224
2226
            self._check_root(ie, parent_invs, tree)
2225
 
        kind = content_summary[0]
 
2227
        if ie.revision is None:
 
2228
            kind = content_summary[0]
 
2229
        else:
 
2230
            # ie is carried over from a prior commit
 
2231
            kind = ie.kind
2226
2232
        # XXX: repository specific check for nested tree support goes here - if
2227
2233
        # the repo doesn't want nested trees we skip it ?
2228
2234
        if (kind == 'tree-reference' and
2319
2325
                return
2320
2326
        elif kind == 'directory':
2321
2327
            if not store:
2322
 
                # all data is meta here, so carry over:
 
2328
                # all data is meta here, nothing specific to directory, so
 
2329
                # carry over:
2323
2330
                ie.revision = parent_entry.revision
2324
2331
                return
2325
2332
            lines = []
2332
2339
                if current_link_target != parent_entry.symlink_target:
2333
2340
                    store = True
2334
2341
            if not store:
 
2342
                # unchanged, carry over.
2335
2343
                ie.revision = parent_entry.revision
2336
2344
                ie.symlink_target = parent_entry.symlink_target
2337
2345
                return
2340
2348
            self._add_text_to_weave(ie.file_id, lines, heads, None)
2341
2349
        elif kind == 'tree-reference':
2342
2350
            if not store:
2343
 
                # all data is meta here, so carry over:
 
2351
                if content_summary[3] != parent_entry.reference_revision:
 
2352
                    store = True
 
2353
            if not store:
 
2354
                # unchanged, carry over.
 
2355
                ie.reference_revision = parent_entry.reference_revision
2344
2356
                ie.revision = parent_entry.revision
2345
2357
                return
 
2358
            ie.reference_revision = content_summary[3]
2346
2359
            lines = []
2347
2360
            self._add_text_to_weave(ie.file_id, lines, heads, None)
2348
2361
        else: