# HG changeset patch # User Yuya Nishihara # Date 2017-12-18 12:15:53 # Node ID b520c8f98e1e47dd221df9cfeeaaa2d19c6dc4e9 # Parent 5bec509dc1ffbb4ed4c682abf3022616ff4a76a4 sshpeer: move docstring to top Also makes it use double quotes consistently. diff --git a/mercurial/sshpeer.py b/mercurial/sshpeer.py --- a/mercurial/sshpeer.py +++ b/mercurial/sshpeer.py @@ -18,9 +18,9 @@ from . import ( ) def _serverquote(s): + """quote a string for the remote shell ... which we assume is sh""" if not s: return s - '''quote a string for the remote shell ... which we assume is sh''' if re.match('[a-zA-Z0-9@%_+=:,./-]*$', s): return s return "'%s'" % s.replace("'", "'\\''")