mirror of
https://github.com/ericonr/util-linux.git
synced 2024-04-21 09:12:35 -05:00
This patch extends the valid --output values with ZONES for the lsmem bash-completion, and adds the --zone option for the chmem bash-completion. Signed-off-by: Andre Wild <wild@linux.vnet.ibm.com> Signed-off-by: Gerald Schaefer <gerald.schaefer@de.ibm.com>
31 lines
501 B
Plaintext
31 lines
501 B
Plaintext
_chmem_module()
|
|
{
|
|
local cur prev OPTS
|
|
COMPREPLY=()
|
|
cur="${COMP_WORDS[COMP_CWORD]}"
|
|
prev="${COMP_WORDS[COMP_CWORD-1]}"
|
|
case $prev in
|
|
'-h'|'--help'|'-V'|'--version')
|
|
return 0
|
|
;;
|
|
esac
|
|
case $cur in
|
|
-*)
|
|
OPTS="
|
|
--enable
|
|
--disable
|
|
--blocks
|
|
--verbose
|
|
--zone
|
|
--help
|
|
--version
|
|
"
|
|
COMPREPLY=( $(compgen -W "${OPTS[*]}" -- $cur) )
|
|
return 0
|
|
;;
|
|
esac
|
|
COMPREPLY=( $(compgen -W "size range blockrange" -- $cur) )
|
|
return 0
|
|
}
|
|
complete -F _chmem_module chmem
|