GNU bug report logs - #23595
25.1.50; file with chinese/japanse chars, vc-diff fails (HG, Git, RCS)

Previous Next

Package: emacs;

Reported by: Uwe Brauer <oub <at> mat.ucm.es>

Date: Sat, 21 May 2016 13:03:01 UTC

Severity: normal

Found in version 25.1.50

Done: Dmitry Gutov <dgutov <at> yandex.ru>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Paul Eggert <eggert <at> cs.ucla.edu>
To: 23595 <at> debbugs.gnu.org
Cc: Uwe Brauer <oub <at> mat.ucm.es>, Eli Zaretskii <eliz <at> gnu.org>, Dmitry Gutov <dgutov <at> yandex.ru>
Subject: bug#23595: 25.1.50; file with chinese/japanse chars, vc-diff fails (HG, Git, RCS)
Date: Mon, 23 May 2016 10:40:40 -0700
On 05/23/2016 09:52 AM, Eli Zaretskii wrote:
> Does "git diff --text" fix this?

I tried something like the following, which as I understand it is the 
procedure recommended for putting UTF-16 files under Git control on 
GNU/Linux hosts (the basic idea is that the repository contains UTF-8 
and the working files contain UTF-16):

* Add the line 'test-chin-jap.tex filter=utf16' to .gitattributes.

* git config filter.utf16.clean 'iconv -f utf-16 -t utf-8'

* git config filter.utf16.smudge 'iconv -f utf-8 -t utf-16'

* Commit the file all over again (as this stores the UTF-8 version in 
the repository, not the UTF-16 version).

* Make a trivial edit to the file in the non-ASCII region.

When I did all all this, Emacs 24.5 works and draft Emacs 25 shows 
mojibake, so we indeed have a regression. The shell command 'git diff' 
works fine, and outputs the difference in UTF-8, but I guess draft Emacs 
25 treats the git diff output as UTF-16.





This bug report was last modified 9 years and 24 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.