Mercurial > public > mercurial-scm > hg
diff mercurial/exchange.py @ 45942:89a2afe31e82
formating: upgrade to black 20.8b1
This required a couple of small tweaks to un-confuse black, but now it
works. Big formatting changes come from:
* Dramatically improved collection-splitting logic upstream
* Black having a strong (correct IMO) opinion that """ is better than '''
Differential Revision: https://phab.mercurial-scm.org/D9430
author | Augie Fackler <raf@durin42.com> |
---|---|
date | Fri, 27 Nov 2020 17:03:29 -0500 |
parents | f0626acf007d |
children | db9e33beb0fb |
line wrap: on
line diff
--- a/mercurial/exchange.py Fri Nov 27 17:00:00 2020 -0500 +++ b/mercurial/exchange.py Fri Nov 27 17:03:29 2020 -0500 @@ -378,14 +378,14 @@ publish=False, opargs=None, ): - '''Push outgoing changesets (limited by revs) from a local + """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() - ''' + """ if opargs is None: opargs = {} pushop = pushoperation( @@ -1510,8 +1510,8 @@ def add_confirm_callback(repo, pullop): - """ adds a finalize callback to transaction which can be used to show stats - to user and confirm the pull before committing transaction """ + """adds a finalize callback to transaction which can be used to show stats + to user and confirm the pull before committing transaction""" tr = pullop.trmanager.transaction() scmutil.registersummarycallback( @@ -1892,7 +1892,11 @@ elif pullop.heads is None: with pullop.remote.commandexecutor() as e: cg = e.callcommand( - b'changegroup', {b'nodes': pullop.fetch, b'source': b'pull',} + b'changegroup', + { + b'nodes': pullop.fetch, + b'source': b'pull', + }, ).result() elif not pullop.remote.capable(b'changegroupsubset'):