File tree Expand file tree Collapse file tree 1 file changed +21
-4
lines changed Expand file tree Collapse file tree 1 file changed +21
-4
lines changed Original file line number Diff line number Diff line change 29
29
# # in a dracut.conf(5) file inside the directory specified for the option
30
30
# # `Global.DracutConfDir` in the ZFSBootMenu `config.yaml`.
31
31
32
- # shellcheck disable=SC1091
33
- [ -f /lib/zfsbootmenu-lib.sh ] && source /lib/zfsbootmenu-lib.sh
32
+ sources=(
33
+ /lib/profiling-lib.sh
34
+ /etc/zfsbootmenu.conf
35
+ /lib/zfsbootmenu-core.sh
36
+ /lib/kmsg-log-lib.sh
37
+ /etc/profile
38
+ )
39
+
40
+ for src in " ${sources[@]} " ; do
41
+ # shellcheck disable=SC1090
42
+ if ! source " ${src} " > /dev/null 2>&1 ; then
43
+ echo -e " \033[0;31mWARNING: ${src} was not sourced; unable to proceed\033[0m"
44
+ exit 1
45
+ fi
46
+ done
47
+
48
+ unset src sources
34
49
35
50
luks=" /dev/disk/by-partlabel/KEYSTORE"
36
51
dm=" /dev/mapper/KEYSTORE"
@@ -78,8 +93,10 @@ while true; do
78
93
79
94
# failed all password attempts
80
95
if [ " ${ret} " -eq 2 ] ; then
81
- if prompt=" Continuing in %0.2d seconds" timed_prompt " [RETURN] continue unlock attempts" " [ESCAPE] emergency shell" " " ; then
82
- continue
96
+ if timed_prompt -e " emergency shell" \
97
+ -r " continue unlock attempts" \
98
+ -p " Continuing in %0.2d seconds" ; then
99
+ continue
83
100
else
84
101
emergency_shell " Unable to unlock LUKS partition"
85
102
fi
You can’t perform that action at this time.
0 commit comments