git.iko.soy/typeable/nixpkgs
on master help sign in
stage-2: shellsheck recommendations
commit62c79a1de8e5e65ead62816b7760e12a6804d44b authorJörg Thalheim <joerg@thalheim.io> dateWed 5 Apr 2017, 00:34 (10 years ago) parente3f031b
1 file changed+3−3
nixos/modules/system/boot/stage-2-init.sh+3−3
nixos/modules/system/boot/stage-2-init.sh+3−3
@@ -6,7 +6,7 @@ export HOME=/root PATH="@path@"
66
77
88# Process the kernel command line.
9−for o in $(cat /proc/cmdline); do
9+for o in $(</proc/cmdline); do
1010 case $o in
1111 boot.debugtrace)
1212 # Show each command.
@@ -107,8 +107,8 @@ fi
107107
108108
109109# Use /etc/resolv.conf supplied by systemd-nspawn, if applicable.
110−if [ -n "@useHostResolvConf@" -a -e /etc/resolv.conf ]; then
111− cat /etc/resolv.conf | resolvconf -m 1000 -a host
110+if [ -n "@useHostResolvConf@" ] && [ -e /etc/resolv.conf ]; then
111+ resolvconf -m 1000 -a host </etc/resolv.conf
112112fi
113113
114114# Log the script output to /dev/kmsg or /run/log/stage-2-init.log.