Patchwork [2,of,6,path,intent] commands: define intent for pull

login
register
mail settings
Submitter Gregory Szorc
Date Sept. 29, 2014, 5:30 a.m.
Message ID <f564a480645468b7172d.1411968622@3.1.168.192.in-addr.arpa>
Download mbox | patch
Permalink /patch/6021/
State Changes Requested
Headers show

Comments

Gregory Szorc - Sept. 29, 2014, 5:30 a.m.
# HG changeset patch
# User Gregory Szorc <gregory.szorc@gmail.com>
# Date 1411967373 25200
#      Sun Sep 28 22:09:33 2014 -0700
# Node ID f564a480645468b7172de5a4a3b4198f3beff64a
# Parent  2f06625fe4d502f43294e9087d9a83398a36fe9f
commands: define intent for pull

Patch

diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -4911,9 +4911,10 @@  def pull(ui, repo, source="default", **o
     See :hg:`help urls` for more information.
 
     Returns 0 on success, 1 if an update had unresolved files.
     """
-    source, branches = hg.parseurl(ui.expandpath(source), opts.get('branch'))
+    source, branches = hg.parseurl(ui.expandpath(source, intent='pull'),
+        opts.get('branch'))
     other = hg.peer(repo, opts, source)
     try:
         ui.status(_('pulling from %s\n') % util.hidepassword(source))
         revs, checkout = hg.addbranchrevs(repo, other, branches,