hgext/mq.py
changeset 4339 077aafddd35f
parent 4334 1cc5fc1d0994
parent 4338 7ae02bce8de2
child 4396 15289406f89c
equal deleted inserted replaced
4336:35ad84669ca5 4339:077aafddd35f
  1584     return 0
  1584     return 0
  1585 
  1585 
  1586 def top(ui, repo, **opts):
  1586 def top(ui, repo, **opts):
  1587     """print the name of the current patch"""
  1587     """print the name of the current patch"""
  1588     q = repo.mq
  1588     q = repo.mq
  1589     t = len(q.applied)
  1589     t = q.series_end()
  1590     if t:
  1590     if t:
  1591         return q.qseries(repo, start=t-1, length=1, status='A',
  1591         return q.qseries(repo, start=t-1, length=1, status='A',
  1592                          summary=opts.get('summary'))
  1592                          summary=opts.get('summary'))
  1593     else:
  1593     else:
  1594         ui.write("No patches applied\n")
  1594         ui.write("No patches applied\n")