mirror of
https://github.com/tpope/vim-fugitive.git
synced 2026-10-09 14:55:57 +08:00
Don't activate autocmds with tmp filenames
This was done in d4fb2a2f5c to fix
filetype modelines, but it appears to no longer be necessary and is
confusing other plugins.
This commit is contained in:
1 parent
b27e71c34b
commit
2bde1d9de6
1 file changed
+2
-6
@@ -1318,7 +1318,7 @@ endfunction
|
|||||||
|
|
||||||
" Section: Buffer auto-commands
|
" Section: Buffer auto-commands
|
||||||
|
|
||||||
function! s:ReplaceCmd(cmd, ...) abort
|
function! s:ReplaceCmd(cmd) abort
|
||||||
let temp = tempname()
|
let temp = tempname()
|
||||||
let err = s:TempCmd(temp, a:cmd)
|
let err = s:TempCmd(temp, a:cmd)
|
||||||
if v:shell_error
|
if v:shell_error
|
||||||
@@ -1330,11 +1330,7 @@ function! s:ReplaceCmd(cmd, ...) abort
|
|||||||
let modelines = &modelines
|
let modelines = &modelines
|
||||||
try
|
try
|
||||||
set modelines=0
|
set modelines=0
|
||||||
if a:0
|
silent keepjumps noautocmd edit!
|
||||||
silent keepjumps noautocmd edit!
|
|
||||||
else
|
|
||||||
silent keepjumps edit!
|
|
||||||
endif
|
|
||||||
finally
|
finally
|
||||||
let &modelines = modelines
|
let &modelines = modelines
|
||||||
try
|
try
|
||||||
|
|||||||
Reference in new issue
Block a user