From b56e1384ca07990b0e536b5d64592936d11f0e37 Mon Sep 17 00:00:00 2001 From: Andy Weidenbaum Date: Sun, 6 Dec 2015 18:01:07 -0800 Subject: [PATCH] make fe function work with multiple selections --- Examples.md | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/Examples.md b/Examples.md index 7f012db..841c5b0 100644 --- a/Examples.md +++ b/Examples.md @@ -7,9 +7,8 @@ You can replace `fzf` command on each example with [`fzf-tmux`](https://github.c # - Bypass fuzzy finder if there's only one match (--select-1) # - Exit if there's no match (--exit-0) fe() { - local file - file=$(fzf --query="$1" --select-1 --exit-0) - [ -n "$file" ] && ${EDITOR:-vim} "$file" + local declare files=($(fzf-tmux --query="$1" --select-1 --exit-0)) + [[ -n "$files" ]] && ${EDITOR:-vim} ${files[@]} } # Modified version where you can press