1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-14 03:30:02 +00:00
trezor-firmware/bash_completion.d/trezorctl.sh

15 lines
305 B
Bash
Raw Normal View History

2016-06-22 15:26:11 +00:00
_trezorctl()
{
local cur prev cmds base
COMPREPLY=()
cur="${COMP_WORDS[COMP_CWORD]}"
prev="${COMP_WORDS[COMP_CWORD-1]}"
2018-10-25 00:24:13 +00:00
cmds=$(trezorctl --help | grep '^ [a-z]' | awk '{ print $1 }')
2016-06-22 15:26:11 +00:00
COMPREPLY=($(compgen -W "${cmds}" -- ${cur}))
return 0
}
complete -F _trezorctl trezorctl