changeset 955:528015bde034

push: print messages from the server Some servers, for example, Bitbucket, output helpful messages. This patch reports the output, if any exist, to the user.
author Sean Farley <sean@farley.io>
date Wed, 02 Dec 2015 17:26:20 -0800
parents 393bde462133
children e7316a108780
files hggit/git_handler.py
diffstat 1 files changed, 8 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/hggit/git_handler.py
+++ b/hggit/git_handler.py
@@ -991,8 +991,15 @@
                 self.ui.status(_("adding objects\n"))
             return self.git.object_store.generate_pack_contents(have, want)
 
+        def callback(remote_info):
+            if not remote_info:
+                remote_info = ''
+            for line in remote_info.split('\n'):
+                self.ui.status(_("remote: %s\n") % line)
+
         try:
-            new_refs = client.send_pack(path, changed, genpack)
+            new_refs = client.send_pack(path, changed, genpack,
+                                        progress=callback)
             if len(change_totals) > 0:
                 self.ui.status(_("added %d commits with %d trees"
                                  " and %d blobs\n") %