Debian Codegraph @

bash-completion/more

raw
1 _more_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 '-n'|'--lines')
9 COMPREPLY=( $(compgen -W "number" -- $cur) )
10 return 0
11 ;;
12 '-h'|'--help'|'-V'|'--version')
13 return 0
14 ;;
15 esac
16 case $cur in
17 -*)
18 OPTS="
19 --exit-on-eof
20 --silent
21 --logical
22 --no-pause
23 --print-over
24 --clean-print
25 --squeeze
26 --plain
27 --lines
28 --help
29 --version
30 "
31 COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
32 return 0
33 ;;
34 +*)
35 OPTS="+number +/pattern"
36 COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
37 return 0
38 ;;
39 esac
40
41 local IFS=$'\n'
42 compopt -o filenames
43 COMPREPLY=( $(compgen -f -- $cur) )
44 return 0
45 }
46 complete -F _more_module more