mirror of
https://github.com/ohmyzsh/ohmyzsh.git
synced 2026-01-02 02:19:06 +01:00
My pkgfile hook wasn't handling multiple results properly. Should be fixed now.
This commit is contained in:
parent
3fb01c9531
commit
3527b4cad4
1 changed files with 5 additions and 2 deletions
|
|
@ -11,7 +11,10 @@ if [[ -x /usr/bin/pkgfile ]]; then
|
||||||
read pid cmd state ppid pgrp session tty_nr tpgid rest < /proc/self/stat
|
read pid cmd state ppid pgrp session tty_nr tpgid rest < /proc/self/stat
|
||||||
[[ $$ -eq $tpgid ]] && return 127
|
[[ $$ -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
|
if [[ -z $pkg ]] && return 127
|
||||||
|
|
||||||
echo "The command \"$1\" can be found in the following packages:"
|
echo "The command \"$1\" can be found in the following packages:"
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue