##// END OF EJS Templates
wireproto: use decorator for the known command
Pierre-Yves David -
r20918:0971939f default
parent child Browse files
Show More
@@ -638,6 +638,7 b' def lookup(repo, proto, key):'
638 success = 0
638 success = 0
639 return "%s %s\n" % (success, r)
639 return "%s %s\n" % (success, r)
640
640
641 @wireprotocommand('known', 'nodes *')
641 def known(repo, proto, nodes, others):
642 def known(repo, proto, nodes, others):
642 return ''.join(b and "1" or "0" for b in repo.known(decodelist(nodes)))
643 return ''.join(b and "1" or "0" for b in repo.known(decodelist(nodes)))
643
644
@@ -792,7 +793,6 b' def unbundle(repo, proto, heads):'
792 os.unlink(tempname)
793 os.unlink(tempname)
793
794
794 commands.update({
795 commands.update({
795 'known': (known, 'nodes *'),
796 'listkeys': (listkeys, 'namespace'),
796 'listkeys': (listkeys, 'namespace'),
797 'lookup': (lookup, 'key'),
797 'lookup': (lookup, 'key'),
798 'pushkey': (pushkey, 'namespace key old new'),
798 'pushkey': (pushkey, 'namespace key old new'),
General Comments 0
You need to be logged in to leave comments. Login now