~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/bundle/commands.py

  • Committer: John Arbash Meinel
  • Date: 2006-06-18 02:21:57 UTC
  • mfrom: (1787 +trunk)
  • mto: This revision was merged to the branch mainline in revision 1794.
  • Revision ID: john@arbash-meinel.com-20060618022157-6e33aa9b67c25e4f
[merge] bzr.dev 1787

Show diffs side-by-side

added added

removed removed

Lines of Context:
15
15
from bzrlib.revision import (common_ancestor, MultipleRevisionSources,
16
16
                             NULL_REVISION)
17
17
from bzrlib.revisionspec import RevisionSpec
18
 
from bzrlib.trace import note
19
18
 
20
19
 
21
20
class cmd_send_changeset(Command):
87
86
        from bzrlib import user_encoding
88
87
        from bzrlib.bundle.serializer import write_bundle
89
88
 
90
 
        target_branch = Branch.open_containing(u'.')[0]
91
 
 
92
89
        if base is None:
93
 
            base = target_branch.get_parent()
94
 
            if base is None:
95
 
                raise errors.BzrCommandError("No base branch known or"
96
 
                                             " specified.")
97
 
            else:
98
 
                note('Using saved location: %s' % base)
99
 
        base_branch = Branch.open(base)
 
90
            base_branch = None
 
91
        else:
 
92
            base_branch = Branch.open(base)
100
93
 
101
94
        # We don't want to lock the same branch across
102
95
        # 2 different branches
103
 
        if target_branch.base == base_branch.base:
104
 
            base_branch = target_branch 
 
96
        target_branch = Branch.open_containing(u'.')[0]
 
97
        if base_branch is not None and target_branch.base == base_branch.base:
 
98
            base_branch = None
105
99
 
106
100
        base_revision = None
107
101
        if revision is None: