From ae5470a5d8e0d740ed5daa4826bbae824ceb902d Mon Sep 17 00:00:00 2001 From: Marty Oehme Date: Sat, 18 Oct 2025 12:58:43 +0200 Subject: [PATCH] nu: Add fuzzy tab completion, remove nvim hardcoding Removed the buffer editor hardcoding to 'nvim', should use the EDITOR env var instead. Added the (currently undocumented?) config option to enable fuzzy completion matching - essentially enables exactly the behavior the 'fzf-tab-complete' plugin does for zsh, only natively in the nushell program. See: https://github.com/nushell/nushell/issues/1275#issuecomment-2964573062 --- terminal/.config/nushell/config.nu | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/terminal/.config/nushell/config.nu b/terminal/.config/nushell/config.nu index def3a4a..f7521ff 100644 --- a/terminal/.config/nushell/config.nu +++ b/terminal/.config/nushell/config.nu @@ -9,10 +9,11 @@ # # This file is loaded after env.nu and before login.nu # -$env.config.show_banner = false # TODO: FOR TESTING PURPOSES +$env.config.show_banner = false $env.config.edit_mode = "vi" -$env.config.buffer_editor = "nvim" +# Enable same behavior as fzf-tab-complete for zsh +$env.config.completions.algorithm = "fuzzy" $env.PROMPT_INDICATOR = "" $env.PROMPT_MULTILINE_INDICATOR = "::: " @@ -28,7 +29,7 @@ $env.PROMPT_INDICATOR_VI_NORMAL = "" # Temporary workaround $env.config.cursor_shape.vi_insert = "line" $env.config.cursor_shape.vi_normal = "block" -# TODO: Currently recommended starship install. Change when it changes. +# load starship prompt mkdir ($nu.data-dir | path join "vendor/autoload") starship init nu | save -f ($nu.data-dir | path join "vendor/autoload/starship.nu") # load atuin history