equal
deleted
inserted
replaced
49 return cmd != '' |
49 return cmd != '' |
50 |
50 |
51 def do_lookup(self): |
51 def do_lookup(self): |
52 arg, key = self.getarg() |
52 arg, key = self.getarg() |
53 assert arg == 'key' |
53 assert arg == 'key' |
54 self.respond(hex(self.repo.lookup(key)) + "\n") |
54 try: |
|
55 r = hex(self.repo.lookup(key)) |
|
56 success = 1 |
|
57 except Exception,inst: |
|
58 r = str(inst) |
|
59 success = 0 |
|
60 self.respond("%s %s\n" % (success, r)) |
55 |
61 |
56 def do_heads(self): |
62 def do_heads(self): |
57 h = self.repo.heads() |
63 h = self.repo.heads() |
58 self.respond(" ".join(map(hex, h)) + "\n") |
64 self.respond(" ".join(map(hex, h)) + "\n") |
59 |
65 |