-
-
-
-
-
-
-
- _nnn () {
- COMPREPLY=()
- local IFS=$' \n'
- local cur=$2 prev=$3
- local -a opts opts_with_args
- opts=(
- -b
- -e
- -h
- -i
- -l
- -n
- -p
- -s
- -S
- -v
- -w
- )
- opts_with_arg=(
- -b
- -p
- )
-
-
- [[ $cur == -* ]] || return 1
-
-
- for opt in "${opts_with_arg[@]}"; do
- [[ $opt == $prev ]] && return 1
- done
-
-
- COMPREPLY=( $(compgen -W "${opts[*]}" -- "$cur") )
- return 0
- }
-
- complete -F _nnn nnn
|