Skip to content
Snippets Groups Projects
Commit b27dc3eb authored by Jack O'Connor's avatar Jack O'Connor Committed by Junegunn Choi
Browse files

[vim] Add parens around piped source commands (#1029)

Previously a command like `echo a && echo b` would get transformed into
`echo a && echo b | fzf`, which only pipes the output of the second
command. Adding parentheses around the source command avoids this issue,
and works on both Unix and Windows.
parent e89eebb7
No related branches found
No related tags found
No related merge requests found
......@@ -366,7 +366,7 @@ try
let source = dict.source
let type = type(source)
if type == 1
let prefix = source.'|'
let prefix = '( '.source.' )|'
elseif type == 3
let temps.input = s:fzf_tempname()
call writefile(source, temps.input)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment