5 cur="${COMP_WORDS[COMP_CWORD]}"
6 prev="${COMP_WORDS[COMP_CWORD-1]}"
22 COMPREPLY=( $(compgen -W "$FLAGS" -- $cur) )
26 # FIXME: how to append to a string with compgen?
28 OUTPUT="FLAG DESCRIPTION STATUS BOOT-STATUS DEVICE"
30 COMPREPLY=( $(compgen -W "$OUTPUT" -S ',' -- $cur) )
34 COMPREPLY=( $(compgen -W "seconds" -- $cur) )
37 '-h'|'--help'|'-V'|'--version')
55 COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
60 COMPREPLY=( $(compgen -f -- ${cur:-"/dev/"}) )
63 complete -F _wdctl_module wdctl