From ddc14a6a5471147e2a38e6b32a7268282f669b0a Mon Sep 17 00:00:00 2001 From: Enno Date: Tue, 9 Dec 2025 00:49:13 +0100 Subject: [PATCH] Avoid cooked terminal mode (#1604) as `:help system()` states When prepended by |:silent| the terminal will not be set to cooked mode. This is meant to be used for commands that do not need the user to type. It avoids stray characters showing up on the screen which require |CTRL-L| to remove. > :silent let f = system('ls *.vim') --- autoload/fzf/vim.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/fzf/vim.vim b/autoload/fzf/vim.vim index 7a1c4d7..7593f37 100755 --- a/autoload/fzf/vim.vim +++ b/autoload/fzf/vim.vim @@ -718,7 +718,7 @@ function! s:get_git_root(dir) return FugitiveWorkTree() endif let dir = len(a:dir) ? a:dir : substitute(split(expand('%:p:h'), '[/\\]\.git\([/\\]\|$\)')[0], '^fugitive://', '', '') - let root = systemlist('git -C ' . shellescape(dir) . ' rev-parse --show-toplevel')[0] + silent let root = systemlist('git -C ' . shellescape(dir) . ' rev-parse --show-toplevel')[0] return v:shell_error ? '' : (len(a:dir) ? fnamemodify(a:dir, ':p') : root) endfunction