hgext/histedit.py
changeset 32291 bd872f64a8ba
parent 32057 e5ffc91a2276
child 32327 3546a771e376
equal deleted inserted replaced
32290:2959c3e986e0 32291:bd872f64a8ba
  1639     if isinstance(nodelist, str):
  1639     if isinstance(nodelist, str):
  1640         nodelist = [nodelist]
  1640         nodelist = [nodelist]
  1641     if os.path.exists(os.path.join(repo.path, 'histedit-state')):
  1641     if os.path.exists(os.path.join(repo.path, 'histedit-state')):
  1642         state = histeditstate(repo)
  1642         state = histeditstate(repo)
  1643         state.read()
  1643         state.read()
  1644         histedit_nodes = set([action.node for action
  1644         histedit_nodes = {action.node for action
  1645                              in state.actions if action.node])
  1645                           in state.actions if action.node}
  1646         common_nodes = histedit_nodes & set(nodelist)
  1646         common_nodes = histedit_nodes & set(nodelist)
  1647         if common_nodes:
  1647         if common_nodes:
  1648             raise error.Abort(_("histedit in progress, can't strip %s")
  1648             raise error.Abort(_("histedit in progress, can't strip %s")
  1649                              % ', '.join(node.short(x) for x in common_nodes))
  1649                              % ', '.join(node.short(x) for x in common_nodes))
  1650     return orig(ui, repo, nodelist, *args, **kwargs)
  1650     return orig(ui, repo, nodelist, *args, **kwargs)