]> git.ipfire.org Git - thirdparty/util-linux.git/blob - bash-completion/raw
bash-completion: rename shell-completion -> bash-completion
[thirdparty/util-linux.git] / bash-completion / raw
1 _raw_module()
2 {
3 local cur
4 COMPREPLY=()
5 cur="${COMP_WORDS[COMP_CWORD]}"
6 case $cur in
7 -*)
8 local OPTS
9 OPTS="-q --query -a --all -h --help -V --version"
10 COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
11 return 0
12 ;;
13 esac
14 COMPREPLY=( $(compgen -W "$(for I in /dev/raw/*; do if [ -e $I ]; then echo $I; fi; done)" -- $cur) )
15 return 0
16 }
17 complete -F _raw_module raw