/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 fetch.py

Provide VersionedFiles.get_annotator.

Show diffs side-by-side

added added

removed removed

Lines of Context:
163
163
        old_path = None
164
164
    invdelta.append((old_path, path, file_id, ie))
165
165
    if base_hexsha != hexsha:
166
 
        store_updater.add_object(blob, ie)
 
166
        store_updater.add_object(blob, ie, path)
167
167
    return invdelta
168
168
 
169
169
 
291
291
    if base_tree is not None and type(base_tree) is Tree:
292
292
        invdelta.extend(remove_disappeared_children(base_inv, old_path, 
293
293
            base_tree, existing_children, lookup_object))
294
 
    store_updater.add_object(tree, ie)
 
294
    store_updater.add_object(tree, ie, path)
295
295
    return invdelta, child_modes
296
296
 
297
297
 
350
350
        base_tree = lookup_object(o.parents[0]).tree
351
351
        base_mode = stat.S_IFDIR
352
352
    store_updater = target_git_object_retriever._get_updater(rev)
353
 
    store_updater.add_object(o, None)
 
353
    store_updater.add_object(o, None, None)
354
354
    lookup_file_id = mapping.get_fileid_map(lookup_object, o.tree).lookup_file_id
355
355
    inv_delta, unusual_modes = import_git_tree(repo.texts,
356
356
            mapping, "", u"", (base_tree, o.tree), base_inv, 
469
469
        """See InterRepository.copy_content."""
470
470
        self.fetch(revision_id, pb, find_ghosts=False)
471
471
 
472
 
    def fetch(self, revision_id=None, pb=None, find_ghosts=False,
473
 
        mapping=None, fetch_spec=None):
474
 
        self.fetch_refs(revision_id=revision_id, pb=pb,
475
 
            find_ghosts=find_ghosts, mapping=mapping, fetch_spec=fetch_spec)
476
 
 
477
472
 
478
473
class InterGitNonGitRepository(InterGitRepository):
479
474
    """Base InterRepository that copies revisions from a Git into a non-Git
480
475
    repository."""
481
476
 
482
 
    def fetch_refs(self, revision_id=None, pb=None, find_ghosts=False,
 
477
    def fetch(self, revision_id=None, pb=None, find_ghosts=False,
483
478
              mapping=None, fetch_spec=None):
484
479
        if mapping is None:
485
480
            mapping = self.source.get_mapping()
626
621
        else:
627
622
            raise AssertionError
628
623
 
629
 
    def fetch_refs(self, revision_id=None, pb=None, find_ghosts=False,
 
624
    def fetch(self, revision_id=None, pb=None, find_ghosts=False,
630
625
              mapping=None, fetch_spec=None, branches=None):
631
626
        if mapping is None:
632
627
            mapping = self.source.get_mapping()