From 559585e31f12d74af9426b69ecacc22f5737d2fa Mon Sep 17 00:00:00 2001 From: Luigi Capriotti Date: Sun, 25 Oct 2009 09:50:07 +0100 Subject: [PATCH] Also allowing hook= to specify files inside the image through file:// prefix. --- scripts/live-bottom/99hook | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/scripts/live-bottom/99hook b/scripts/live-bottom/99hook index 17895ca..8809800 100755 --- a/scripts/live-bottom/99hook +++ b/scripts/live-bottom/99hook @@ -32,7 +32,14 @@ log_begin_msg "Executing custom hook script" # live-initramfs script cd /root -chroot /root wget "${HOOK}" + +if [ $(echo "${HOOK}" | grep file:\/\/) ] +then + LOCALFILE=$(echo ${HOOK} | sed "s/file\:\/\///") + cp ${LOCALFILE} /root +else + chroot /root wget "${HOOK}" +fi FILE="$(basename ${HOOK})" -- 2.1.4