aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCem Keylan <cem@ckyln.com>2020-03-02 13:38:16 +0300
committerCem Keylan <cem@ckyln.com>2020-03-02 13:38:16 +0300
commitdefbc312f9e5b00da65fddd7e92e4c51b6496bb7 (patch)
tree9bd007d6a21ce010241c2199657c4e3b11699fc5
parentdf61744030207d7b70ef93bb559c2b682069a300 (diff)
downloadinit-defbc312f9e5b00da65fddd7e92e4c51b6496bb7.tar.gz
only announce functions if they are meant to run
-rwxr-xr-xrc.boot24
1 files 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 \