From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#19045: 25.0.50; [PATCH] vc-git-print-log use --follow Date: Sun, 04 Feb 2018 23:58:53 +0200 Organization: LINKOV.NET Message-ID: <87d11kquw2.fsf@mail.linkov.net> References: <87d28rt4jl.fsf@telefonica.net> <874lmxloo1.fsf@mail.linkov.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1517781569 31211 195.159.176.226 (4 Feb 2018 21:59:29 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Sun, 4 Feb 2018 21:59:29 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (x86_64-pc-linux-gnu) To: 19045@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Feb 04 22:59:25 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eiSJZ-0006uE-4T for geb-bug-gnu-emacs@m.gmane.org; Sun, 04 Feb 2018 22:59:09 +0100 Original-Received: from localhost ([::1]:44847 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eiSLa-0002EZ-HE for geb-bug-gnu-emacs@m.gmane.org; Sun, 04 Feb 2018 17:01:14 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:40833) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1eiSLR-0002Dj-7x for bug-gnu-emacs@gnu.org; Sun, 04 Feb 2018 17:01:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1eiSLO-00085k-2Y for bug-gnu-emacs@gnu.org; Sun, 04 Feb 2018 17:01:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:49534) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1eiSLN-00085G-UM for bug-gnu-emacs@gnu.org; Sun, 04 Feb 2018 17:01:01 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1eiSLN-00036M-NM for bug-gnu-emacs@gnu.org; Sun, 04 Feb 2018 17:01:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 04 Feb 2018 22:01:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 19045 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 19045-submit@debbugs.gnu.org id=B19045.151778161311861 (code B ref 19045); Sun, 04 Feb 2018 22:01:01 +0000 Original-Received: (at 19045) by debbugs.gnu.org; 4 Feb 2018 22:00:13 +0000 Original-Received: from localhost ([127.0.0.1]:57431 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eiSKa-00035E-Rx for submit@debbugs.gnu.org; Sun, 04 Feb 2018 17:00:13 -0500 Original-Received: from sub3.mail.dreamhost.com ([69.163.253.7]:35072 helo=homiemail-a20.g.dreamhost.com) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1eiSKZ-000356-L5 for 19045@debbugs.gnu.org; Sun, 04 Feb 2018 17:00:11 -0500 Original-Received: from homiemail-a20.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a20.g.dreamhost.com (Postfix) with ESMTP id 1EAB57EC064 for <19045@debbugs.gnu.org>; Sun, 4 Feb 2018 14:00:11 -0800 (PST) Original-Received: from localhost.linkov.net (m91-129-107-8.cust.tele2.ee [91.129.107.8]) (using TLSv1 with cipher DHE-RSA-AES128-SHA (128/128 bits)) (No client certificate requested) (Authenticated sender: jurta@jurta.org) by homiemail-a20.g.dreamhost.com (Postfix) with ESMTPSA id 798A97EC060 for <19045@debbugs.gnu.org>; Sun, 4 Feb 2018 14:00:10 -0800 (PST) In-Reply-To: <874lmxloo1.fsf@mail.linkov.net> (Juri Linkov's message of "Sat, 03 Feb 2018 23:59:58 +0200") 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:142913 Archived-At: > Too bad that a new useful customizable variable > vc-git-print-log-follow is not mentioned in NEWS.26. > > It works quite well, but only with the following fix > that puts more restrictions - it checks not only > for a directory, but also if it is a single file. > > The whole patch is intended for the emacs-26 branch: Pushed to the emacs-26 branch. Here is a related problem. The executed git command is not shown completely in the echo area, this is ok since there is not much space. But the git command is truncated in the *Messages* buffer, this is bad because sometimes there is a need to inspect the command run by git with its command line switches in its entirety, especially in case of errors. The command string is truncated in =E2=80=98vc-do-command=E2=80=99 and le= t-bound to =E2=80=98full-command=E2=80=99, so we need to add an untruncated command = string to the *Messages* buffer. Here is an example of what will be in *Messages* after this patch: Running git --no-pager log -p -L1001,1039:vc-git.el Running git --no-pager log -p -L... . in background... Running git --no-pager log -p -L... . in background... done This patch is for the master branch: diff --git a/lisp/vc/vc-dispatcher.el b/lisp/vc/vc-dispatcher.el index b0d2221..efdd29e 100644 --- a/lisp/vc/vc-dispatcher.el +++ b/lisp/vc/vc-dispatcher.el @@ -313,6 +313,8 @@ vc-do-command (status 0)) (when files (setq squeezed (nconc squeezed files))) + (let ((inhibit-message t)) + (message "Running %s %s" command (vc-delistify squeezed))) (let (;; Since some functions need to parse the output ;; from external commands, set LC_MESSAGES to C. (process-environment (cons "LC_MESSAGES=3DC" process-environment)= )