Mercurial > public > mercurial-scm > hg-stable
diff mercurial/hg.py @ 48252:607e9322fc89
path: return path instance directly from get_pull_paths
This means the caller has to do a bit more work, however it give access to the
`path` instance and the information it contains.
Differential Revision: https://phab.mercurial-scm.org/D11673
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Fri, 15 Oct 2021 02:44:14 +0200 |
parents | 1d70fb83ff4a |
children | 7d1e60244561 |
line wrap: on
line diff
--- a/mercurial/hg.py Fri Oct 15 02:36:54 2021 +0200 +++ b/mercurial/hg.py Fri Oct 15 02:44:14 2021 +0200 @@ -1261,13 +1261,14 @@ (remoterepo, incomingchangesetlist, displayer) parameters, and is supposed to contain only code that can't be unified. """ - srcs = urlutil.get_pull_paths(repo, ui, [source], opts.get(b'branch')) + srcs = urlutil.get_pull_paths(repo, ui, [source]) srcs = list(srcs) if len(srcs) != 1: msg = _(b'for now, incoming supports only a single source, %d provided') msg %= len(srcs) raise error.Abort(msg) - source, branches = srcs[0] + path = srcs[0] + source, branches = urlutil.parseurl(path.rawloc, opts.get(b'branch')) if subpath is not None: subpath = urlutil.url(subpath) if subpath.isabs():