From 2bde1d9de608f7086c8b2eaeb3e295107bce9d92 Mon Sep 17 00:00:00 2001 From: Tim Pope Date: Thu, 2 May 2019 23:43:41 -0400 Subject: [PATCH] Don't activate autocmds with tmp filenames This was done in d4fb2a2f5c2023f477beae6aef47cf0457351e6e to fix filetype modelines, but it appears to no longer be necessary and is confusing other plugins. --- autoload/fugitive.vim | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/autoload/fugitive.vim b/autoload/fugitive.vim index 7543c16..19d831a 100644 --- a/autoload/fugitive.vim +++ b/autoload/fugitive.vim @@ -1318,7 +1318,7 @@ endfunction " Section: Buffer auto-commands -function! s:ReplaceCmd(cmd, ...) abort +function! s:ReplaceCmd(cmd) abort let temp = tempname() let err = s:TempCmd(temp, a:cmd) if v:shell_error @@ -1330,11 +1330,7 @@ function! s:ReplaceCmd(cmd, ...) abort let modelines = &modelines try set modelines=0 - if a:0 - silent keepjumps noautocmd edit! - else - silent keepjumps edit! - endif + silent keepjumps noautocmd edit! finally let &modelines = modelines try