aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--bash-completion9
1 files changed, 6 insertions, 3 deletions
diff --git a/bash-completion b/bash-completion
index 2bcce1d..b9388c4 100644
--- a/bash-completion
+++ b/bash-completion
@@ -29,7 +29,7 @@ _ponymix() {
fi
case $word in
- --devtype)
+ --devtype|-t)
# look ahead to next word
if [[ ${COMP_WORDS[i+1]} ]]; then
devtype=${COMP_WORDS[i+1]}
@@ -38,6 +38,9 @@ _ponymix() {
--devtype=*)
devtype=${word#--devtype=}
;;
+ -t*)
+ devtype=${word#-t}
+ ;;
--sink|--output)
devtype=sink
;;
@@ -53,9 +56,9 @@ _ponymix() {
case $prev in
--card|-c)
- mapfile -t devices < <(\ponymix list-cards-short 2>/dev/null)
+ mapfile -t cards < <(\ponymix list-cards-short 2>/dev/null)
local IFS=$'\n'
- COMPREPLY=($(compgen -W '$(printf "%s\n" "${devices[@]//\ /\\ }")' -- "$cur"))
+ COMPREPLY=($(compgen -W '$(printf "%s\n" "${cards[@]//\ /\\ }")' -- "$cur"))
;;
--device|-d)
while IFS=$'\t' read _ dev idx _; do