X-Git-Url: http://git.grml.org/?a=blobdiff_plain;f=scripts%2Flive-functions;h=8bf9c38e7a5f3456c35ef2bc3899bd7d1c9cb34e;hb=refs%2Ftags%2Fdebian%2F1.157.3-1;hp=49b4a3af4ef6e0b46d37133789a5adb2ce89423f;hpb=4ed4f4268f00b9d335ed32ec8b1ca4d4468e5dbb;p=live-boot-grml.git diff --git a/scripts/live-functions b/scripts/live-functions index 49b4a3a..8bf9c38 100644 --- a/scripts/live-functions +++ b/scripts/live-functions @@ -21,7 +21,7 @@ really_export () STRING="${1}" VALUE="$(eval echo -n \${$STRING})" - if [ -f /live.vars ] && cat /live.vars | grep -sq "export ${STRING}" + if [ -f /live.vars ] && grep -sq "export ${STRING}" /live.vars then sed -i -e 's/\('${STRING}'=\).*$/\1'${VALUE}'/' /live.vars else @@ -60,6 +60,16 @@ lang2locale() { fi } +# Override maybe_break from scripts/functions +maybe_break() +{ + if [ "${break}" = "$1" ]; then + # Call original panic + . /scripts/functions + panic "Spawning shell within the initramfs" + fi +} + # Override panic from scripts/functions panic() {