Comments
Patch
@@ -578,3 +578,19 @@
remote: abort: this is an exercise
abort: pull failed on remote
[255]
+
+abort with default error message when there is a ssh problem when pulling
+
+ $ hg pull ssh://brokenrepository
+ pulling from ssh://brokenrepository/
+ remote: ssh: Could not resolve hostname brokenrepository: Name or service not known
+ abort: no suitable response from remote hg!
+ [255]
+
+abort with configured error message when there is a ssh problem when pulling
+
+ $ hg pull ssh://brokenrepository --config ssh.errormessage="SSH error"
+ pulling from ssh://brokenrepository/
+ remote: ssh: Could not resolve hostname brokenrepository: Name or service not known
+ abort: SSH error!
+ [255]
@@ -204,8 +204,9 @@
self._pipeo = doublepipe(self.ui, self._pipeo, self._pipee)
def badresponse():
- self._abort(error.RepoError(_('no suitable response from '
- 'remote hg')))
+ msg = self.ui.config("ssh", "errormessage",
+ _("no suitable response from remote hg"))
+ self._abort(error.RepoError(msg))
try:
# skip any noise generated by remote shell