From 5a4dfdb67b900be02658987742c03f997f86aa56 Mon Sep 17 00:00:00 2001 From: mequidis Date: Sun, 20 Feb 2022 09:16:41 +0200 Subject: [PATCH] Fix - fzfcd would quit when no path is chosen and cd to ~ --- .config/scripts/util/cdfzf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.config/scripts/util/cdfzf b/.config/scripts/util/cdfzf index 748d522..8fff559 100644 --- a/.config/scripts/util/cdfzf +++ b/.config/scripts/util/cdfzf @@ -3,4 +3,6 @@ selection=$(fzf) selection=$(echo $selection | sed 's,/[^/]*$,,') -cd $selection +if [ ! $selection = "\S" ]; then + cd $selection +fi