My pkgfile hook wasn't handling multiple results properly. Should be fixed now.

This commit is contained in:
Simon Gomizelj 2011-11-28 14:14:45 -05:00
commit 3527b4cad4

View file

@ -11,10 +11,13 @@ if [[ -x /usr/bin/pkgfile ]]; then
read pid cmd state ppid pgrp session tty_nr tpgid rest < /proc/self/stat
[[ $$ -eq $tpgid ]] && return 127
pkg=$(pkgfile -b -v -- $1)
saveIFS=$IFS; IFS=$'\n';
pkg=($(pkgfile -b -v -- $1))
IFS=$saveIFS
if [[ -z $pkg ]] && return 127
echo "The command \"$1\" can be found in the following packages:"
for p in $pkg; echo " $p"
for p in $pkg; echo " $p"
}
fi