From 31b15405e96cbc24e0cdfd404d09cfb0e84c4b77 Mon Sep 17 00:00:00 2001 From: Kid <44045911+kidonng@users.noreply.github.com> Date: Thu, 21 Nov 2024 05:06:53 +0800 Subject: [PATCH] Add completion for `path basename -E/--no-extension` (#10863) --- share/completions/path.fish | 1 + 1 file changed, 1 insertion(+) diff --git a/share/completions/path.fish b/share/completions/path.fish index e9f3e2a37..92fb1f999 100644 --- a/share/completions/path.fish +++ b/share/completions/path.fish @@ -14,6 +14,7 @@ complete -f -c path -n "test (count (commandline -xpc)) -lt 2" -a sort -d 'Sort complete -f -c path -n "test (count (commandline -xpc)) -ge 2" -s q -l quiet -d "Only return status, no output" complete -f -c path -n "test (count (commandline -xpc)) -ge 2" -s z -l null-in -d "Handle NULL-delimited input" complete -f -c path -n "test (count (commandline -xpc)) -ge 2" -s Z -l null-out -d "Print NULL-delimited output" +complete -f -c path -n "test (count (commandline -xpc)) -ge 2; and contains -- (commandline -xpc)[2] basename" -s E -l no-extension -d "Remove the extension" complete -f -c path -n "test (count (commandline -xpc)) -ge 2; and contains -- (commandline -xpc)[2] filter is" -s v -l invert -d "Invert meaning of filters" complete -f -c path -n "test (count (commandline -xpc)) -ge 2; and contains -- (commandline -xpc)[2] filter is" -s t -l type -d "Filter by type" -x -a '(__fish_append , file link dir block char fifo socket)' complete -f -c path -n "test (count (commandline -xpc)) -ge 2; and contains -- (commandline -xpc)[2] filter is" -s f -d "Filter files"