comparison hgext/histedit.py @ 48215:d8cff8564f5a

chistedit: rename a confusingly named variable I would expect `ctxs` contain instances of some class from the `context` module but it actually contains instances of `histeditrule`. Differential Revision: https://phab.mercurial-scm.org/D11653
author Martin von Zweigbergk <martinvonz@google.com>
date Tue, 12 Oct 2021 14:12:41 -0700
parents 1895027c5051
children c820866c52f9
comparison
equal deleted inserted replaced
48214:1895027c5051 48215:d8cff8564f5a
1714 if not revs: 1714 if not revs:
1715 raise error.InputError( 1715 raise error.InputError(
1716 _(b'%s is not an ancestor of working directory') % short(root) 1716 _(b'%s is not an ancestor of working directory') % short(root)
1717 ) 1717 )
1718 1718
1719 ctxs = [] 1719 rules = []
1720 for i, r in enumerate(revs): 1720 for i, r in enumerate(revs):
1721 ctxs.append(histeditrule(ui, repo[r], i)) 1721 rules.append(histeditrule(ui, repo[r], i))
1722 with util.with_lc_ctype(): 1722 with util.with_lc_ctype():
1723 rc = curses.wrapper(functools.partial(_chisteditmain, repo, ctxs)) 1723 rc = curses.wrapper(functools.partial(_chisteditmain, repo, rules))
1724 curses.echo() 1724 curses.echo()
1725 curses.endwin() 1725 curses.endwin()
1726 if rc is False: 1726 if rc is False:
1727 ui.write(_(b"histedit aborted\n")) 1727 ui.write(_(b"histedit aborted\n"))
1728 return 0 1728 return 0