completions/bind: complete ctrl/alt modifier abbreviations

This commit is contained in:
Johannes Altmanninger 2024-05-22 22:35:31 +02:00
parent de7f39d627
commit 2f84f76cc2

View File

@ -66,7 +66,9 @@ function __fish_bind_complete
set -l token (commandline -ct)
if test (count $argv) = 0 && set -l prefix (string match -r -- '(.*,)?(ctrl-|alt-|shift-)*' $token)
printf '%sctrl-\tCtrl modifier…\n' $prefix
printf '%sc-\tCtrl modifier…\n' $prefix
printf '%salt-\tAlt modifier…\n' $prefix
printf '%sa-\tAlt modifier…\n' $prefix
printf '%sshift-\tShift modifier…\n' $prefix
set -l key_names minus comma backspace delete escape \
enter up down left right pageup pagedown home end insert tab \