From 7a1c945645e6ea3c995ba21b4288b7a048340e67 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment=20Pit--Claudel?= Date: Fri, 4 Aug 2017 17:03:20 +0200 Subject: [PATCH] Follow renames in vc-git-region-history * lisp/vc/vc-git.el (vc-git-region-history): Pass --follow. This requires a path spec, so pass that too. --- lisp/vc/vc-git.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lisp/vc/vc-git.el b/lisp/vc/vc-git.el index cc3e295..6830951 100644 --- a/lisp/vc/vc-git.el +++ b/lisp/vc/vc-git.el @@ -1159,8 +1159,10 @@ vc-git-region-history (- (+ curno curcnt) (+ headno headcnt))))) (setq lto (- lto (or to-offset last-offset))) (setq lfrom (- lfrom (or to-offset last-offset))))) - (vc-git-command buffer 'async nil "log" "-p" ;"--follow" ;FIXME: not supported? - (format "-L%d,%d:%s" lfrom lto (file-relative-name file)))) + (vc-git-command buffer 'async nil "log" "-p" "--follow" + (format "-L%d,%d:%s" lfrom lto (file-relative-name file)) + ;; Must include one path spec for --follow to work + (file-relative-name file))) (require 'diff-mode) -- 2.7.4