aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--defaults/initrd.scripts26
-rw-r--r--defaults/linuxrc6
2 files changed, 14 insertions, 18 deletions
diff --git a/defaults/initrd.scripts b/defaults/initrd.scripts
index da15db76..3be18b5b 100644
--- a/defaults/initrd.scripts
+++ b/defaults/initrd.scripts
@@ -821,7 +821,7 @@ setup_overlayfs() {
local workdir="${overlay}/.work"
local static=/mnt/livecd
- rundebugshell overlayfs
+ run_debug_shell overlayfs
for i in "${overlay}" "${static}"
do
[ ! -d "${i}" ] && run mkdir -p "${i}"
@@ -1001,6 +1001,16 @@ run() {
return ${retval}
}
+run_debug_shell() {
+ is_debug || return
+
+ good_msg 'Starting debug shell as requested by "debug" option.'
+ good_msg "Run '${BOLD}gksosreport${NORMAL}' to generate debug report"
+ good_msg "in case you want to file a bug report."
+ good_msg "Stopping by: ${1}"
+ run_shell
+}
+
run_emergency_shell() {
echo
gksosreport
@@ -2516,20 +2526,6 @@ cdupdate() {
fi
}
-rundebugshell() {
- if is_debug
- then
- good_msg 'Starting debug shell as requested by "debug" option.'
- good_msg "Run '${BOLD}gksosreport${NORMAL}' to generate debug report"
- good_msg "in case you want to file a bug report."
- else
- return 0
- fi
-
- good_msg "Stopping by: ${1}"
- run_shell
-}
-
do_resume() {
local device=$(find_real_device "${REAL_RESUME}")
if [ -z "${device}" ]
diff --git a/defaults/linuxrc b/defaults/linuxrc
index 78881301..8356aeaa 100644
--- a/defaults/linuxrc
+++ b/defaults/linuxrc
@@ -572,7 +572,7 @@ else
fi
# Run debug shell if requested
-rundebugshell "before starting udevd"
+run_debug_shell "before starting udevd"
# Initialize udev
if [ ! -f "/etc/udev/hwdb.bin" ]
@@ -670,7 +670,7 @@ run mkdir -p "${NEW_ROOT}"
CHROOT="${NEW_ROOT}"
# Run debug shell if requested
-rundebugshell "before setting up the root filesystem"
+run_debug_shell "before setting up the root filesystem"
if [ "${CDROOT}" = '1' ]
then
@@ -1331,7 +1331,7 @@ then
fi
# Run debug shell if requested
-rundebugshell "before entering switch_root"
+run_debug_shell "before switch_root"
if [ "${GK_PRESERVE_RUN}" = '0' ]
then