# bash completion for nethogs(8) -*- shell-script -*- proc _nethogs { local cur prev words cword _init_completion || return match $prev { with -d # expect integer value setglobal COMPREPLY = ''( $( compgen -W '{0..9}' ) ) compopt -o nospace return } if [[ "$cur" == -* ]] { setglobal COMPREPLY = ''( $( compgen -W '$( _parse_usage "$1" -h )' -- "$cur" ) ) return } _available_interfaces -a } && complete -F _nethogs nethogs # ex: ts=4 sw=4 et filetype=sh