]> git.ipfire.org Git - thirdparty/util-linux.git/blob - bash-completion/chrt
dmesg: add --follow-new
[thirdparty/util-linux.git] / bash-completion / chrt
1 _chrt_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 '-T'|'--sched-runtime'|'-P'|'--sched-period'|'-D'|'--sched-deadline')
12 COMPREPLY=( $(compgen -W "nanoseconds" -- $cur) )
13 return 0
14 ;;
15 esac
16 case $cur in
17 -*)
18 OPTS="
19 --all-tasks
20 --batch
21 --deadline
22 --fifo
23 --help
24 --idle
25 --max
26 --other
27 --pid
28 --reset-on-fork
29 --rr
30 --sched-deadline
31 --sched-period
32 --sched-runtime
33 --verbose
34 --version
35 "
36 COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
37 return 0
38 ;;
39 esac
40 local i
41 for i in ${COMP_WORDS[*]}; do
42 case $i in
43 '-p'|'--pid')
44 COMPREPLY=( $(compgen -W "$(cd /proc && echo [0-9]*)" -- $cur) )
45 return 0
46 ;;
47 esac
48 done
49 COMPREPLY=( $(compgen -c -- $cur) )
50 return 0
51 }
52 complete -F _chrt_module chrt