Mercurial > public > mercurial-scm > hg
comparison mercurial/merge.py @ 36010:46a54de96a54
merge: cut import cycle at merge -> extensions
This seems less bad because checking fsmonitor looks like a temporary hack,
and cmdutil -> mergemod should be a valid dependency.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Tue, 06 Feb 2018 22:55:02 +0900 |
parents | 55e8efa2451a |
children | 4fe2041007ed |
comparison
equal
deleted
inserted
replaced
36009:55e8efa2451a | 36010:46a54de96a54 |
---|---|
23 nullrev, | 23 nullrev, |
24 ) | 24 ) |
25 from . import ( | 25 from . import ( |
26 copies, | 26 copies, |
27 error, | 27 error, |
28 extensions, | |
29 filemerge, | 28 filemerge, |
30 match as matchmod, | 29 match as matchmod, |
31 obsutil, | 30 obsutil, |
32 pycompat, | 31 pycompat, |
33 scmutil, | 32 scmutil, |
1990 # considered stable. | 1989 # considered stable. |
1991 fsmonitorwarning = repo.ui.configbool('fsmonitor', 'warn_when_unused') | 1990 fsmonitorwarning = repo.ui.configbool('fsmonitor', 'warn_when_unused') |
1992 fsmonitorthreshold = repo.ui.configint('fsmonitor', | 1991 fsmonitorthreshold = repo.ui.configint('fsmonitor', |
1993 'warn_update_file_count') | 1992 'warn_update_file_count') |
1994 try: | 1993 try: |
1994 # avoid cycle: extensions -> cmdutil -> merge | |
1995 from . import extensions | |
1995 extensions.find('fsmonitor') | 1996 extensions.find('fsmonitor') |
1996 fsmonitorenabled = repo.ui.config('fsmonitor', 'mode') != 'off' | 1997 fsmonitorenabled = repo.ui.config('fsmonitor', 'mode') != 'off' |
1997 # We intentionally don't look at whether fsmonitor has disabled | 1998 # We intentionally don't look at whether fsmonitor has disabled |
1998 # itself because a) fsmonitor may have already printed a warning | 1999 # itself because a) fsmonitor may have already printed a warning |
1999 # b) we only care about the config state here. | 2000 # b) we only care about the config state here. |