From a9cdb7dfe97530ba005986efe52966f978c4077c Mon Sep 17 00:00:00 2001 From: Jonathan Hodgson Date: Wed, 30 Dec 2020 22:21:58 +0000 Subject: [PATCH] Fix fuzzy creation of new file FZF exits with a status of 1 if nothing was selected. This is often the case though if we are creating a new file so I added `|| true` to make bash continue anyway --- inc/fzf | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/inc/fzf b/inc/fzf index e0c2424..8cdff1e 100644 --- a/inc/fzf +++ b/inc/fzf @@ -16,8 +16,8 @@ ${YELLOW}ctrl+e $WHITE edit selected ${YELLOW}ctrl+d $WHITE delete selected output="$(listEntries | fzf --header="$header" --header-lines=2 --print-query \ --delimiter=" +" --with-nth=3,5 --height=100% \ - --expect="ctrl-n,ctrl-o,ctrl-e,ctrl-d" \ - --preview='bash -c "fzfPreview {}"')" + --expect="ctrl-n,ctrl-v,ctrl-e,ctrl-d" \ + --preview='bash -c "fzfPreview {}"')" || true query="$(echo "$output" | sed -n '1p')" operation="$(echo "$output" | sed -n '2p')"