Add list serial devices feature

For convenience, add a --list-devices option which lists the available
serial devices.
This commit is contained in:
Martin Lund 2022-02-08 22:44:48 +01:00
parent 6310f28d2c
commit 7a2a18232d
8 changed files with 55 additions and 2 deletions

View file

@ -21,6 +21,7 @@ _tio()
-m --map \
-v --version \
-t --timestamp \
-i --list-devices \
-h --help"
# Complete the arguments to the options.
@ -70,6 +71,10 @@ _tio()
COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
return 0
;;
-i | --list-devices)
COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
return 0
;;
-v | --version)
COMPREPLY=( $(compgen -W "${opts}" -- ${cur}) )
return 0