##// END OF EJS Templates
templatekw: deprecate p1rev/p2rev/p1node/p2node in favor of p1/p2
Yuya Nishihara -
r40511:592feb3f default
parent child Browse files
Show More
@@ -708,14 +708,14 b' def showp2(context, mapping):'
708 @templatekeyword('p1rev', requires={'ctx'})
708 @templatekeyword('p1rev', requires={'ctx'})
709 def showp1rev(context, mapping):
709 def showp1rev(context, mapping):
710 """Integer. The repository-local revision number of the changeset's
710 """Integer. The repository-local revision number of the changeset's
711 first parent, or -1 if the changeset has no parents."""
711 first parent, or -1 if the changeset has no parents. (DEPRECATED)"""
712 ctx = context.resource(mapping, 'ctx')
712 ctx = context.resource(mapping, 'ctx')
713 return ctx.p1().rev()
713 return ctx.p1().rev()
714
714
715 @templatekeyword('p2rev', requires={'ctx'})
715 @templatekeyword('p2rev', requires={'ctx'})
716 def showp2rev(context, mapping):
716 def showp2rev(context, mapping):
717 """Integer. The repository-local revision number of the changeset's
717 """Integer. The repository-local revision number of the changeset's
718 second parent, or -1 if the changeset has no second parent."""
718 second parent, or -1 if the changeset has no second parent. (DEPRECATED)"""
719 ctx = context.resource(mapping, 'ctx')
719 ctx = context.resource(mapping, 'ctx')
720 return ctx.p2().rev()
720 return ctx.p2().rev()
721
721
@@ -723,7 +723,7 b' def showp2rev(context, mapping):'
723 def showp1node(context, mapping):
723 def showp1node(context, mapping):
724 """String. The identification hash of the changeset's first parent,
724 """String. The identification hash of the changeset's first parent,
725 as a 40 digit hexadecimal string. If the changeset has no parents, all
725 as a 40 digit hexadecimal string. If the changeset has no parents, all
726 digits are 0."""
726 digits are 0. (DEPRECATED)"""
727 ctx = context.resource(mapping, 'ctx')
727 ctx = context.resource(mapping, 'ctx')
728 return ctx.p1().hex()
728 return ctx.p1().hex()
729
729
@@ -731,7 +731,7 b' def showp1node(context, mapping):'
731 def showp2node(context, mapping):
731 def showp2node(context, mapping):
732 """String. The identification hash of the changeset's second
732 """String. The identification hash of the changeset's second
733 parent, as a 40 digit hexadecimal string. If the changeset has no second
733 parent, as a 40 digit hexadecimal string. If the changeset has no second
734 parent, all digits are 0."""
734 parent, all digits are 0. (DEPRECATED)"""
735 ctx = context.resource(mapping, 'ctx')
735 ctx = context.resource(mapping, 'ctx')
736 return ctx.p2().hex()
736 return ctx.p2().hex()
737
737
General Comments 0
You need to be logged in to leave comments. Login now