From 23f5252a855f81071406c0788cf0ba667ceb5268 Mon Sep 17 00:00:00 2001 From: Greg Anders Date: Fri, 13 Sep 2019 11:28:50 -0600 Subject: [PATCH] Filter blank completions --- autoload/fish.vim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/autoload/fish.vim b/autoload/fish.vim index 2c4d894..37a5738 100644 --- a/autoload/fish.vim +++ b/autoload/fish.vim @@ -52,7 +52,7 @@ function! fish#Complete(findstart, base) let l:completions = \ system('fish -c "complete -C'.shellescape(a:base).'"') let l:cmd = substitute(a:base, '\v\S+$', '', '') - for l:line in split(l:completions, '\n') + for l:line in filter(split(l:completions, '\n'), 'len(v:val)') let l:tokens = split(l:line, '\t') call add(l:results, {'word': l:cmd.l:tokens[0], \'abbr': l:tokens[0],