/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 breezy/git/branch.py

  • Committer: Breezy landing bot
  • Author(s): Jelmer Vernooij
  • Date: 2020-01-12 15:16:27 UTC
  • mfrom: (7441.1.2 strip-segment-parameters)
  • Revision ID: breezy.the.bot@gmail.com-20200112151627-meh6feoulbz777ns
Add strip_segment_parameters function.

Merged from https://code.launchpad.net/~jelmer/brz/strip-segment-parameters/+merge/377479

Show diffs side-by-side

added added

removed removed

Lines of Context:
544
544
    def set_parent(self, location):
545
545
        cs = self.repository._git.get_config()
546
546
        remote = self._get_origin(cs)
547
 
        this_url = urlutils.split_segment_parameters(self.user_url)[0]
 
547
        this_url = urlutils.strip_segment_parameters(self.user_url)
548
548
        target_url, branch, ref = bzr_url_to_git_url(location)
549
549
        location = urlutils.relative_url(this_url, target_url)
550
550
        cs.set((b"remote", remote), b"url", location)