comparison mercurial/bundle2.py @ 21135:98fbf3adfd83

bundle2: add capabilities support in `replycaps` part This part now contains a list of supported capabilities.
author Pierre-Yves David <pierre-yves.david@fb.com>
date Thu, 17 Apr 2014 11:32:30 -0400
parents 2f8c4fa237f5
children b6fd496e5c72
comparison
equal deleted inserted replaced
21134:2f8c4fa237f5 21135:98fbf3adfd83
695 695
696 @parthandler('replycaps') 696 @parthandler('replycaps')
697 def handlereplycaps(op, inpart): 697 def handlereplycaps(op, inpart):
698 """Notify that a reply bundle should be created 698 """Notify that a reply bundle should be created
699 699
700 Will convey bundle capability at some point too.""" 700 the part payload is a list of capabilities (one per line)"""
701 caps = [c for c in inpart.read().splitlines() if c]
701 if op.reply is None: 702 if op.reply is None:
702 op.reply = bundle20(op.ui) 703 op.reply = bundle20(op.ui, caps)
703 704