Skip to content

Commit cb8dfaa

Browse files
committed
zfsbootmenu-core: show enabled/disabled hooks in zreport
1 parent 42d4529 commit cb8dfaa

File tree

1 file changed

+16
-2
lines changed

1 file changed

+16
-2
lines changed

zfsbootmenu/lib/zfsbootmenu-core.sh

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1924,6 +1924,8 @@ emergency_shell() {
19241924
# returns: nothing
19251925

19261926
zreport() {
1927+
local hook
1928+
19271929
colorize white "System Report\n\n"
19281930

19291931
(
@@ -1948,9 +1950,21 @@ zreport() {
19481950
)
19491951

19501952
colorize orange "\n>> ZFSBootMenu commandline\n"
1951-
get_zbm_kcl | kcl_assemble
1953+
get_zbm_kcl | kcl_assemble ; echo
1954+
1955+
colorize orange "\n>> Enabled hooks\n"
1956+
for hook in /libexec/hooks/*.d/*; do
1957+
[ -x "${hook}" ] && echo "* $( colorize green "${hook}")"
1958+
done
1959+
1960+
colorize orange "\n>> Disabled hooks\n"
1961+
for hook in /libexec/hooks/*.d/*; do
1962+
[ -f "${hook}" ] || continue
1963+
[ -x "${hook}" ] && continue
1964+
echo "* $( colorize red "${hook}")"
1965+
done
19521966

1953-
colorize orange "\n\n>> ZFS/SPL module information\n"
1967+
colorize orange "\n>> ZFS/SPL module information\n"
19541968
echo "$( modinfo -F filename spl ): $( modinfo -F version spl )"
19551969
echo "$( modinfo -F filename zfs ): $( modinfo -F version zfs )"
19561970

0 commit comments

Comments
 (0)