Submitter | Sean Farley |
---|---|
Date | Oct. 15, 2015, 8:20 p.m. |
Message ID | <4e97de9a18fd8d23692b.1444940402@laptop.office.atlassian.com> |
Download | mbox | patch |
Permalink | /patch/11109/ |
State | Accepted |
Commit | 16e69e6b357b0a1a05c920989e408676cb670168 |
Headers | show |
Comments
On 10/15/2015 09:20 PM, Sean Farley wrote: > # HG changeset patch > # User Sean Farley <sean@farley.io> > # Date 1444802693 25200 > # Tue Oct 13 23:04:53 2015 -0700 > # Node ID 4e97de9a18fd8d23692bc428339846960eeaad8a > # Parent 83b738235f1bfc33a943a63a5d0f5527ac2da736 > exchange: add oparg to push so that extensions can wrap pushop LGTM (but out of queuing mode)
On Thu, 2015-10-15 at 13:20 -0700, Sean Farley wrote: > # HG changeset patch > # User Sean Farley <sean@farley.io> > # Date 1444802693 25200 > # Tue Oct 13 23:04:53 2015 -0700 > # Node ID 4e97de9a18fd8d23692bc428339846960eeaad8a > # Parent 83b738235f1bfc33a943a63a5d0f5527ac2da736 > exchange: add oparg to push so that extensions can wrap pushop Queued for default, thanks.
Patch
diff --git a/mercurial/exchange.py b/mercurial/exchange.py --- a/mercurial/exchange.py +++ b/mercurial/exchange.py @@ -258,20 +258,24 @@ bookmsgmap = {'update': (_("updating boo 'delete': (_("deleting remote bookmark %s\n"), _('deleting remote bookmark %s failed!\n')), } -def push(repo, remote, force=False, revs=None, newbranch=False, bookmarks=()): +def push(repo, remote, force=False, revs=None, newbranch=False, bookmarks=(), + opargs=None): '''Push outgoing changesets (limited by revs) from a local repository to remote. Return an integer: - None means nothing to push - 0 means HTTP error - 1 means we pushed and remote head count is unchanged *or* we have outgoing changesets but refused to push - other values as described by addchangegroup() ''' - pushop = pushoperation(repo, remote, force, revs, newbranch, bookmarks) + if opargs is None: + opargs = {} + pushop = pushoperation(repo, remote, force, revs, newbranch, bookmarks, + **opargs) if pushop.remote.local(): missing = (set(pushop.repo.requirements) - pushop.remote.local().supported) if missing: msg = _("required features are not"