summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDave Reisner <dreisner@archlinux.org>2012-12-16 01:16:25 +0100
committerDave Reisner <dreisner@archlinux.org>2013-01-12 22:59:33 +0100
commitf28a70ca5eedccbbf60319801bff00d061a51065 (patch)
tree3d1eb052e8119de119f1599357ac6090743f2846
parentdae9fa1991222170b6453a887fe7ea9c7f160e2c (diff)
downloadmkinitcpio-f28a70ca5eedccbbf60319801bff00d061a51065.tar.gz
mkinitcpio-f28a70ca5eedccbbf60319801bff00d061a51065.tar.xz
functions: always force a PATH lookup for type
Signed-off-by: Dave Reisner <dreisner@archlinux.org>
-rw-r--r--functions6
1 files changed, 3 insertions, 3 deletions
diff --git a/functions b/functions
index 4d7b2ea..90ee02e 100644
--- a/functions
+++ b/functions
@@ -216,7 +216,7 @@ funcgrep() {
list_hookpoints() {
local funcs script
- script=$(PATH=$_d_hooks type -p "$1") || return 0
+ script=$(PATH=$_d_hooks type -P "$1") || return 0
mapfile -t funcs < <(funcgrep '^run_[[:alnum:]_]+' "$script")
@@ -467,7 +467,7 @@ add_runscript() {
local funcs fn script hookname=${BASH_SOURCE[1]##*/}
- if ! script=$(PATH=$_d_hooks type -p "$hookname"); then
+ if ! script=$(PATH=$_d_hooks type -P "$hookname"); then
error "runtime script for \`%s' not found" "$hookname"
return
fi
@@ -615,7 +615,7 @@ run_build_hook() {
local MODULES= BINARIES= FILES= SCRIPT=
# find script in install dirs
- if ! script=$(PATH=$_d_install type -p "$hook"); then
+ if ! script=$(PATH=$_d_install type -P "$hook"); then
error "Hook '$hook' cannot be found"
return 1
fi