[xinput completions] Support devices with : in name

[ci skip]
This commit is contained in:
Mahmoud Al-Qudsi 2020-06-28 23:02:13 -05:00
parent a966ace4a9
commit da21ab5892

View File

@ -4,7 +4,7 @@ set -l cmds version list get-feedbacks set-pointer set-mode set-ptr-feedback set
function __fish_xinput_devices
# Yeah, this includes a "↳" char
# There's either this or printing only name or id, not both
xinput list --short | string replace -r '^[\W↳]*([\w/ ]+)\s+id=([0-9]+).*$' '$2\t$1'
xinput list --short | string replace -r '^[\W↳]*(.*?)\s+id=([0-9]+).*$' '$2\t$1'
end
complete -c xinput -f -n "not __fish_seen_subcommand_from $cmds" -a "$cmds"