From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nikolay Kudryavtsev Newsgroups: gmane.emacs.bugs Subject: bug#23076: 24.5; vc-git: add a new variable for log output coding system Date: Tue, 12 Apr 2016 01:12:21 +0300 Message-ID: <570C2145.6030100@gmail.com> References: <56EFE033.7080900@gmail.com> <56F04527.6010901@gmail.com> <83fuv4s4cr.fsf@gnu.org> <57017E45.7050605@gmail.com> <83pou5o0uh.fsf@gnu.org> <5708F5CA.3080509@gmail.com> <83egafhrpf.fsf@gnu.org> <57090E2F.4020702@gmail.com> <83bn5ij0sy.fsf@gnu.org> <83oa9hh2bo.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8; format=flowed Content-Transfer-Encoding: 8bit X-Trace: ger.gmane.org 1460412805 23336 80.91.229.3 (11 Apr 2016 22:13:25 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 11 Apr 2016 22:13:25 +0000 (UTC) Cc: 23076@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Apr 12 00:13:14 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1apk53-0001Wj-Lk for geb-bug-gnu-emacs@m.gmane.org; Tue, 12 Apr 2016 00:13:13 +0200 Original-Received: from localhost ([::1]:35424 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apk53-0002SC-0P for geb-bug-gnu-emacs@m.gmane.org; Mon, 11 Apr 2016 18:13:13 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:49248) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apk4z-0002QY-7E for bug-gnu-emacs@gnu.org; Mon, 11 Apr 2016 18:13:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1apk4u-0005uX-4O for bug-gnu-emacs@gnu.org; Mon, 11 Apr 2016 18:13:09 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:47455) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1apk4u-0005uD-1B for bug-gnu-emacs@gnu.org; Mon, 11 Apr 2016 18:13:04 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1apk4s-0003VI-82 for bug-gnu-emacs@gnu.org; Mon, 11 Apr 2016 18:13:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Nikolay Kudryavtsev Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 11 Apr 2016 22:13:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 23076 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 23076-submit@debbugs.gnu.org id=B23076.146041275713436 (code B ref 23076); Mon, 11 Apr 2016 22:13:02 +0000 Original-Received: (at 23076) by debbugs.gnu.org; 11 Apr 2016 22:12:37 +0000 Original-Received: from localhost ([127.0.0.1]:59792 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1apk4T-0003Ud-0P for submit@debbugs.gnu.org; Mon, 11 Apr 2016 18:12:37 -0400 Original-Received: from mail-lf0-f66.google.com ([209.85.215.66]:35294) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1apk4R-0003UQ-19 for 23076@debbugs.gnu.org; Mon, 11 Apr 2016 18:12:35 -0400 Original-Received: by mail-lf0-f66.google.com with SMTP id o124so21837747lfb.2 for <23076@debbugs.gnu.org>; Mon, 11 Apr 2016 15:12:34 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:subject:to:references:cc:message-id:date:user-agent :mime-version:in-reply-to:content-transfer-encoding; bh=BxlBUsiHhCDQUsCDWijI1oeaW8vUnTaVfJLa+fZCwl4=; b=MPdxh1dUDSsy+rOBMbhCJ9dMroCWv1h5cwiAuGgljtdws6nnCxNXjyMPMxmpX40hnm 8y1+jz7PbXoP46clD59tbOXjMOZoJtpz07ooruZdvetHRfh9tr5k03QpBjOby1ssCUNP D9me9HH3UZtQsdk4a7cVFSaEr/ypJLnT8byivwnvil4ONUjyf7flGFwWxeWQqqruqpQp 81pvsLJLd1g9ShzMdIScpj0suw1nKGJvWCNJfFEN1bFsmINueO603kMwENKxOdgHCz+e 1XdIr+VGrRqIHQmbcEFTd0pz73B51N6kYK5pkUO4Opa1g5ODJNE6h4vcnOwsotUiu+lU 8S1A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:subject:to:references:cc:message-id:date :user-agent:mime-version:in-reply-to:content-transfer-encoding; bh=BxlBUsiHhCDQUsCDWijI1oeaW8vUnTaVfJLa+fZCwl4=; b=VfmDostJQ296AMdPNM+tbRkEt6Jz/KRAVlkFpoSMTUlW3zDVr5qeoSG1aL5P9+0idt nHsDTZyZDev/y9KZ+zaxT2spC28XxwLlU5G2oqCLUE88rZ/r5JTMqmKVOf77+ozsILVW FQLwfEmPYJzKRApLq3H485e80JgmGnE6LPEq2BUwMiNWFz8RIpwPE2icQ7V9S4F5gtve 9a3oFtfQb1xgDqygHnMv0dqBr29x42xKuzIA0yxeoyLiVsMT/xN+JKBTO6EaS7uWDaaA IJqczboQLcs0Aso7ua4uYyvADRjLsVz03Wwu5RdBCjdX5alHazU7Y0+UdMwNyV1HHwgp dmow== X-Gm-Message-State: AOPr4FVgr1JuWa3kNfpORjUofFAF4CrnaAf67VHWN6DPWuOpN9SbUxEWaJTWvIBTLptfmw== X-Received: by 10.25.196.23 with SMTP id u23mr3027550lff.129.1460412749258; Mon, 11 Apr 2016 15:12:29 -0700 (PDT) Original-Received: from [192.168.199.2] (broadband-95-84-209-126.nationalcablenetworks.ru. [95.84.209.126]) by smtp.gmail.com with ESMTPSA id i8sm4828158lbj.30.2016.04.11.15.12.28 (version=TLSv1/SSLv3 cipher=OTHER); Mon, 11 Apr 2016 15:12:28 -0700 (PDT) X-Google-Original-From: Nikolay Kudryavtsev User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:38.0) Gecko/20100101 Thunderbird/38.7.2 In-Reply-To: <83oa9hh2bo.fsf@gnu.org> X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:116393 Archived-At: Eli, sorry for not describing this before in more details, but my data in those 3 points was wrong, as I said in the next letter after that one. So here's how -F flag actually behaves with regards to encodings: 1. When you try to commit using the -F flag with Russian message.txt in windows-1251, it gives that warning: > Warning: commit message did not conform to UTF-8. > You may want to amend it after fixing the message, or set the config > variable i18n.commitencoding to the encoding your project uses. Then it recodes the log message as windows-1252(sic!). So the russian: Коммит. Would become: Êîììèò. 2. Doing the same while having commitencoding = windows-1251 results in a legitimate commit. 3. Having message.txt in utf-8 and commitencoding = windows-1251 results in: РљРѕРјРјРёС‚. This is utf-8 recoded to windows-1251. > My conclusion from these experiments is different. It seems like Git > simply records the log messages and outputs them without any > conversions or interpretation, disregarding i18n.commitEncoding. That's not true. commitencoding has the immediate effect on the log encoding. You can see this by setting commitencoding = windows-1251 and doing git log for that test repo. Log output is decoded by commitencoding, but logoutputencoding overrides it. You can test this by: commitencoding = windows-1251 logoutputencoding = utf-8 This would make git log work again for that repo. -- Best Regards, Nikolay Kudryavtsev