Mercurial > hg-stable
view tests/failfilemerge.py @ 31456:067add650129
encoding: factor out unicode variants of from/tolocal()
Unfortunately, these functions will be commonly used on Python 3.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Mon, 13 Mar 2017 09:11:08 -0700 |
parents | 318a24b52eeb |
children | c0ce60459d84 |
line wrap: on
line source
# extension to emulate interrupting filemerge._filemerge from __future__ import absolute_import from mercurial import ( error, extensions, filemerge, ) def failfilemerge(filemergefn, premerge, repo, mynode, orig, fcd, fco, fca, labels=None): raise error.Abort("^C") return filemergefn(premerge, repo, mynode, orig, fcd, fco, fca, labels) def extsetup(ui): extensions.wrapfunction(filemerge, '_filemerge', failfilemerge)