~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/branch.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2011-08-17 18:13:57 UTC
  • mfrom: (5268.7.29 transport-segments)
  • Revision ID: pqm@pqm.ubuntu.com-20110817181357-y5q5eth1hk8bl3om
(jelmer) Allow specifying the colocated branch to use in the branch URL,
 and retrieving the branch name using ControlDir._get_selected_branch.
 (Jelmer Vernooij)

Show diffs side-by-side

added added

removed removed

Lines of Context:
780
780
                                  other_branch=None):
781
781
        """See Branch.generate_revision_history"""
782
782
        graph = self.repository.get_graph()
 
783
        (last_revno, last_revid) = self.last_revision_info()
783
784
        known_revision_ids = [
784
 
            self.last_revision_info(),
 
785
            (last_revid, last_revno),
785
786
            (_mod_revision.NULL_REVISION, 0),
786
787
            ]
787
788
        if last_rev is not None:
1540
1541
        # For bzr native formats must_fetch is just the tip, and if_present_fetch
1541
1542
        # are the tags.
1542
1543
        must_fetch = set([self.last_revision()])
1543
 
        try:
1544
 
            if_present_fetch = set(self.tags.get_reverse_tag_dict())
1545
 
        except errors.TagsNotSupported:
1546
 
            if_present_fetch = set()
 
1544
        if_present_fetch = set()
 
1545
        c = self.get_config()
 
1546
        include_tags = c.get_user_option_as_bool('branch.fetch_tags',
 
1547
                                                 default=False)
 
1548
        if include_tags:
 
1549
            try:
 
1550
                if_present_fetch = set(self.tags.get_reverse_tag_dict())
 
1551
            except errors.TagsNotSupported:
 
1552
                pass
1547
1553
        must_fetch.discard(_mod_revision.NULL_REVISION)
1548
1554
        if_present_fetch.discard(_mod_revision.NULL_REVISION)
1549
1555
        return must_fetch, if_present_fetch