From 11a246232ce9fae3f5db9935349b3a7635438a55 Mon Sep 17 00:00:00 2001 From: simo Date: Sun, 19 Feb 2006 00:13:39 +0000 Subject: progress patch from iphitus --- tupkg/client/tupkg | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'tupkg/client') diff --git a/tupkg/client/tupkg b/tupkg/client/tupkg index 021e647b..87ffac01 100755 --- a/tupkg/client/tupkg +++ b/tupkg/client/tupkg @@ -109,8 +109,15 @@ class ClientSocket: def sendFiles(self): for i in self.files: i.fd.seek(i.cur_done) + print "Uploading:", i.filename, str(i.size/1024), "kb" + sdone = 0 while i.fd.tell() < i.size: + sdone+=1 self.socket.sendall(i.fd.read(1024)) + if sdone % 100 == 0: + print "\r", + print str(sdone), "of", str(i.size/1024), "kb", + sys.stdout.flush() reply = self.readMsg(1) print reply self.sendMsg("ack") -- cgit v1.2.3-24-g4f1b