7 # Print a message and wait for enter
8 if [ -x /bin/plymouth ] && plymouth --ping
10 plymouth message --text="$@"
11 plymouth watch-keystroke | read nunya
14 _log_msg "Waiting: ${@} ... \n"
20 VALUE="$(eval echo -n \${$STRING})"
22 if [ -f /live.vars ] && grep -sq "export ${STRING}" /live.vars
24 sed -i -e 's/\('${STRING}'=\).*$/\1'${VALUE}'/' /live.vars
26 echo "export ${STRING}=\"${VALUE}\"" >> /live.vars
29 eval export "${STRING}"="${VALUE}"
34 if [ "$1" != "C" ]; then
35 # Match the language code with 3rd field in languagelist
36 line=$(grep -v "^#" /usr/share/live-boot/languagelist | cut -f1,3,6 -d\; | grep -v ';C$' | grep "^$langpart;")
37 if [ -n "$line" ]; then
38 if [ "$(echo "$line" | grep -c '')" -gt 1 ]; then
39 # More than one match; try matching the
42 if [ "$countrypart" = "$1" ]; then
43 countryline="$(echo "$line" | head -n1)"
44 echo "${countryline##*;}"
47 countrypart="${countrypart%%[@.]*}"
48 countryline="$(echo "$line" | grep ";$countrypart;" | head -n1 || true)"
49 if [ "$countryline" ]; then
50 echo "${countryline##*;}"
61 # Override maybe_break from scripts/functions
64 if [ "${break}" = "$1" ]; then
67 panic "Spawning shell within the initramfs"
71 # Override panic from scripts/functions
74 DEB_1="\033[1;31m .''\`. \033[0m"
75 DEB_2="\033[1;31m: :' : \033[0m"
76 DEB_3="\033[1;31m\`. \`'\` \033[0m"
77 DEB_4="\033[1;31m \`- \033[0m"
79 LIVELOG="\033[1;37m/live-boot.log\033[0m"
80 DEBUG="\033[1;37mdebug\033[0m"
82 # Reset redirections to avoid buffering
89 printf " ${DEB_2} \033[1;37mBOOT FAILED!\033[0m\n"
91 printf " ${DEB_4} This Debian Live image failed to boot.\n\n"
93 printf " Please file a bug against the 'live-boot' package or email the Debian\n"
94 printf " Live mailing list at <debian-live@lists.debian.org>, making sure to note the\n"
95 printf " exact version, name and distribution of the image you were attempting to boot.\n\n"
97 printf " The file ${LIVELOG} contains some debugging information but booting with the\n"
98 printf " ${DEBUG} command-line parameter will greatly increase its verbosity which is\n"
99 printf " extremely useful when diagnosing issues.\n\n"
101 if [ -n "${panic}" ]; then
102 printf " live-boot will now restart your system. "
104 printf " live-boot will now start a shell. "
106 printf "The error message was:\n\n "
108 # Call original panic