[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#19045: 25.0.50; [PATCH] vc-git-print-log use --follow

From: Eli Zaretskii
Subject: bug#19045: 25.0.50; [PATCH] vc-git-print-log use --follow
Date: Mon, 12 Feb 2018 20:09:15 +0200

> From: Juri Linkov <address@hidden>
> Cc: Andreas Schwab <address@hidden>,  address@hidden
> Date: Sun, 11 Feb 2018 23:22:59 +0200
> > Juri, can you please re-check with directories?  They seem to work
> > fine here, so disabling them in this case sounds unnecessary.
> Please clarify where directories work fine: in git command line
> or in Emacs using vc-git?

The latter.

> In the command line of git version 1.9.1 running git log on two files
> (command line copied from *Messages* when vc-command-messages is t)
>   git --no-pager log --no-color --follow -n 2000 -- vc-dispatcher.el vc-git.el
> fails with the error:
>   usage: git logs can only follow renames on one pathname at a time
> whereas running git on one directory ‘vc’
>   git --no-pager log --no-color --follow -n 2000 -- vc
> doesn't fail.  Although I can't confirm the correctness of the output log:
> it seems the option ‘--follow’ has no effect on directories.

Even if it's true, it means --follow doesn't do any harm when invoked
on directories, and we shouldn't disallow that.

> Now there is a different story for vc-git.el.  There are 4 versions of it:
> 1. the initial version without the option added in ‘vc-git-print-log’
> 2. the old version that always used "--follow"
> 3. the previous version that added "--follow" only
>    when the arg ‘files’ contains no directories
> 4. the current version that additionally checks the length of ‘files’
>    and adds "--follow" only for a single file in ‘files’.
> Which version did you check?

I tried #2.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]