filemerge: use 'basic' as the default of '[ui] mergemarkers' for safety
Before this patch, 'detailed' is used as the default of '[ui] mergemarkers'. This embeds non-ASCII characters in tags, branches, bookmarks, author and/or commit descriptions into merged files in the encoding specified by '--encoding' global option, 'HGENCODING' or other locale setting environment variables. But, if files to be merged use another encoding, this behavior breaks consistency of encoding in merged files. For example, ISO-2022-JP or EUC-JP are sometimes used as the file encoding for Japanese characters, because of historical and/or environmental reasons, even though UTF-8 or Shift-JIS are ordinarily used as the terminal encoding. This can't be resolved automatically, because Mercurial doesn't aware encoding of managed files. This patch uses 'basic' as the default of '[ui] mergemarkers' to avoid embedding encoding sensitive characters for safety. This patch puts '[ui] mergemarkers = detailed' into default hgrc file for tests, to reduce changes for tests in this patch.
Showing
- mercurial/filemerge.py 1 addition, 1 deletionmercurial/filemerge.py
- mercurial/help/config.txt 9 additions, 2 deletionsmercurial/help/config.txt
- tests/run-tests.py 1 addition, 0 deletionstests/run-tests.py
- tests/test-basic.t 1 addition, 0 deletionstests/test-basic.t
- tests/test-commandserver.py.out 2 additions, 0 deletionstests/test-commandserver.py.out
Loading
Please register or sign in to comment