From c5a18e7eb390422c3a88932cfcd46f92e4b241a0 Mon Sep 17 00:00:00 2001 From: Chris Lamb Date: Wed, 1 Oct 2008 00:56:30 +0100 Subject: [PATCH] Use "grep -qs" over "grep -q" for compatibility (see grep(1)) Signed-off-by: Chris Lamb --- scripts/live-bottom/06hostname | 2 +- scripts/live-bottom/12fstab | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/scripts/live-bottom/06hostname b/scripts/live-bottom/06hostname index 75ea801..ba71fce 100755 --- a/scripts/live-bottom/06hostname +++ b/scripts/live-bottom/06hostname @@ -32,7 +32,7 @@ log_begin_msg "Setting hostname" # live-initramfs script # Change hostname only if it is not set -if [ ! -f /root/etc/hostname ] || grep -q localhost\.localdomain /root/etc/hostname +if [ ! -f /root/etc/hostname ] || grep -qs localhost\.localdomain /root/etc/hostname then echo "${HOSTNAME}" > /root/etc/hostname else diff --git a/scripts/live-bottom/12fstab b/scripts/live-bottom/12fstab index 2dba37a..f38eee7 100755 --- a/scripts/live-bottom/12fstab +++ b/scripts/live-bottom/12fstab @@ -33,7 +33,7 @@ log_begin_msg "Configuring fstab" # live-initramfs script # Create a fake fstab only if it is not already there -if [ ! -f "${FSTAB}" ] || grep -q 'UNCONFIGURED FSTAB FOR BASE SYSTEM' "${FSTAB}" +if [ ! -f "${FSTAB}" ] || grep -qs 'UNCONFIGURED FSTAB FOR BASE SYSTEM' "${FSTAB}" then cat >> ${FSTAB} << EOF # /etc/fstab: static file system information. -- 2.1.4