]>
Commit | Line | Data |
---|---|---|
cd094a05 MY |
1 | _exch_module() |
2 | { | |
3 | local cur prev OPTS | |
4 | COMPREPLY=() | |
5 | cur="${COMP_WORDS[COMP_CWORD]}" | |
6 | prev="${COMP_WORDS[COMP_CWORD-1]}" | |
7 | case $prev in | |
8 | '-h'|'--help'|'-V'|'--version') | |
9 | return 0 | |
10 | ;; | |
11 | esac | |
12 | case $cur in | |
13 | -*) | |
14 | OPTS=' | |
15 | --help | |
16 | --version' | |
17 | COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) ) | |
18 | return 0 | |
19 | ;; | |
20 | esac | |
21 | local IFS=$'\n' | |
22 | compopt -o filenames | |
23 | COMPREPLY=( $(compgen -f -- $cur) ) | |
24 | return 0 | |
25 | } | |
26 | complete -F _exch_module exch |