[arch-projects] [initscripts] [PATCH 3/3] rc.sysinit: Remove redundant command substitution
Lukas Fleischer
archlinux at cryptocrack.de
Fri Feb 3 08:07:02 EST 2012
Invoke `grep -q` and check its return value instead of checking whether
grep(1) produces non-empty output.
Signed-off-by: Lukas Fleischer <archlinux at cryptocrack.de>
---
rc.sysinit | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/rc.sysinit b/rc.sysinit
index 458239e..88c72a0 100755
--- a/rc.sysinit
+++ b/rc.sysinit
@@ -39,7 +39,7 @@ if [[ ! -a /usr/lib ]] ; then
printf "${C_FAIL}/usr is not mounted. This is not supported.${C_OTHER}\n"
fi
-if [[ ! $(grep devtmpfs /proc/filesystems) ]] ; then
+if ! grep -q devtmpfs /proc/filesystems; then
printf "${C_FAIL}Your kernel does not have devtmpfs support. This is not supported.${C_OTHER}\n"
fi
--
1.7.9
More information about the arch-projects
mailing list