Mercurial > hg
comparison mercurial/utils/urlutil.py @ 49738:afcf59039b5d
path: clarify document of `get_clone_path`
This return a url as `bytes`, not a `path` object.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Fri, 02 Dec 2022 03:51:27 +0100 |
parents | f4626b74b941 |
children | ffe8dd945f19 |
comparison
equal
deleted
inserted
replaced
49737:4cedae992ed1 | 49738:afcf59039b5d |
---|---|
580 path = get_unique_pull_path_obj(action, ui, source=source) | 580 path = get_unique_pull_path_obj(action, ui, source=source) |
581 return parseurl(path.rawloc, default_branches) | 581 return parseurl(path.rawloc, default_branches) |
582 | 582 |
583 | 583 |
584 def get_clone_path(ui, source, default_branches=()): | 584 def get_clone_path(ui, source, default_branches=()): |
585 """return the `(origsource, path, branch)` selected as clone source""" | 585 """return the `(origsource, url, branch)` selected as clone source""" |
586 urls = [] | 586 urls = [] |
587 if source is None: | 587 if source is None: |
588 if b'default' in ui.paths: | 588 if b'default' in ui.paths: |
589 urls.extend(p.rawloc for p in ui.paths[b'default']) | 589 urls.extend(p.rawloc for p in ui.paths[b'default']) |
590 else: | 590 else: |