##// END OF EJS Templates
template: fix shortest(node) function in pure mercurial...
Durham Goode -
r20371:6f3fb6a9 default
parent child Browse files
Show More
@@ -368,7 +368,14 b' def shortest(context, mapping, args):'
368 cl = mapping['ctx']._repo.changelog
368 cl = mapping['ctx']._repo.changelog
369 def isvalid(test):
369 def isvalid(test):
370 try:
370 try:
371 cl.index.partialmatch(test)
371 try:
372 cl.index.partialmatch(test)
373 except AttributeError:
374 # Pure mercurial doesn't support partialmatch on the index.
375 # Fallback to the slow way.
376 if cl._partialmatch(test) is None:
377 return False
378
372 try:
379 try:
373 int(test)
380 int(test)
374 return False
381 return False
General Comments 0
You need to be logged in to leave comments. Login now