From 95e8d5c2681335f11a6ba93c8919e39c4ac85066 Mon Sep 17 00:00:00 2001 From: Noah Masur <7386960+nmasur@users.noreply.github.com> Date: Sun, 14 Jan 2024 22:33:29 -0500 Subject: [PATCH] switch to proximity fzf project switcher also sadly must remove the shortcut names because sorting requires full paths --- modules/common/shell/fzf.nix | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/modules/common/shell/fzf.nix b/modules/common/shell/fzf.nix index a36b0bb..a2a2337 100644 --- a/modules/common/shell/fzf.nix +++ b/modules/common/shell/fzf.nix @@ -1,4 +1,4 @@ -{ config, ... }: { +{ config, pkgs, ... }: { # FZF is a fuzzy-finder for the terminal @@ -16,10 +16,9 @@ --search-path $HOME/dev \ --type directory \ --exact-depth 2 \ + | ${pkgs.proximity-sort}/bin/proximity-sort . \ | sed 's/\\/$//' \ - | fzf \ - --delimiter '/' \ - --with-nth 6.. \ + | fzf --tiebreak=index \ ) and cd $projdir and commandline -f execute