From defbc312f9e5b00da65fddd7e92e4c51b6496bb7 Mon Sep 17 00:00:00 2001 From: Cem Keylan Date: Mon, 2 Mar 2020 13:38:16 +0300 Subject: only announce functions if they are meant to run --- rc.boot | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/rc.boot b/rc.boot index e660bcc..ce0841d 100755 --- a/rc.boot +++ b/rc.boot @@ -34,17 +34,17 @@ out "Mounting pseudo filesystems..."; { mnt /dev/shm -o mode=1777,nosuid,nodev -nt tmpfs shm } -out "Setting dmesg level..."; { - [ -n "$dmesg_level" ] && dmesg -n$dmesg_level +[ "$dmesg_level" ] && { + out "Setting dmesg level..." + dmesg -n$dmesg_level } -out "Starting eudev..."; { - command -v udevd >/dev/null && { - udevd --daemon - udevadm trigger --action=add --type=subsystems - udevadm trigger --action=add --type=devices - udevadm settle - } +command -v udevd >/dev/null && { + out "Starting eudev..." + udevd --daemon + udevadm trigger --action=add --type=subsystems + udevadm trigger --action=add --type=devices + udevadm settle } out "Remounting rootfs as ro..."; { @@ -94,11 +94,11 @@ out "Setting hostname..."; { printf '%s\n' "${hostname:-carbs-linux}" > /proc/sys/kernel/hostname } 2>/dev/null -out "Getting keymap settings..."; { - [ -n "$keymap" ] && loadkmap < "$keymap" +[ "$keymap" ] && { + out "Loading keymap settings..." + loadkmap < "$keymap" } - out "Loading sysctl settings..."; { find /run/sysctl.d \ /etc/sysctl.d \ -- cgit v1.2.3