From 62d172060527804f600c02eafc19b246caa6834e Mon Sep 17 00:00:00 2001 From: Johannes Altmanninger Date: Sat, 16 Mar 2024 10:30:46 +0100 Subject: [PATCH] completions/htop: fix --sort-key completions --- share/completions/htop.fish | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/share/completions/htop.fish b/share/completions/htop.fish index 89c343373..1e958a685 100644 --- a/share/completions/htop.fish +++ b/share/completions/htop.fish @@ -7,7 +7,7 @@ complete -c htop -l no-colour -d 'Start htop in monochrome mode' complete -c htop -l filter -s F -d 'Filter processes by terms matching the commands' -x complete -c htop -l help -s h -d 'Show help and exit' complete -c htop -l pid -s p -d 'Show only given PIDs' -xa '(__fish_append , (__fish_complete_pids))' -complete -c htop -l sort-key -s s -d 'Sort column' -xa '(htop --sort-key help)' +complete -c htop -l sort-key -s s -d 'Sort column' -xa '(htop --sort-key help | sed -E "s/^\s*([^[:space:]]*)\s*(.*)/\1\t\2/")' complete -c htop -l user -s u -d 'Monitor given user' -xa '(__fish_complete_users)' complete -c htop -l no-unicode -s U -d 'Do not use unicode but ASCII characters for graph meters' complete -c htop -l no-mouse -s M -d 'Disable support of mouse control'