diff options
-rw-r--r-- | completions/insmod | 4 | ||||
-rw-r--r-- | completions/modprobe | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/completions/insmod b/completions/insmod index de619c01..545f8bc5 100644 --- a/completions/insmod +++ b/completions/insmod @@ -9,8 +9,8 @@ _insmod() if [[ $cword -eq 1 ]]; then _filedir '@(?(k)o?(.gz))' else # do module parameter completion - COMPREPLY=( $( compgen -W "$( /sbin/modinfo -p ${words[1]} \ - 2>/dev/null | cut -d: -f1 )" -- "$cur" ) ) + COMPREPLY=( $( compgen -W "$( PATH="$PATH:/sbin" modinfo \ + -p ${words[1]} 2>/dev/null | cut -d: -f1 )" -- "$cur" ) ) fi } && complete -F _insmod insmod insmod.static diff --git a/completions/modprobe b/completions/modprobe index 6db1b351..cf35f4b9 100644 --- a/completions/modprobe +++ b/completions/modprobe @@ -73,8 +73,8 @@ _modprobe() _filedir '@(?(k)o?(.gz))' elif [[ -n "$module" ]]; then # do module parameter completion - COMPREPLY=( $( compgen -W "$( /sbin/modinfo -p "$module" \ - 2>/dev/null | cut -d: -f1 )" -- "$cur" ) ) + COMPREPLY=( $( compgen -W "$( PATH="$PATH:/sbin" modinfo \ + -p "$module" 2>/dev/null | cut -d: -f1 )" -- "$cur" ) ) else _modules $version fi |