From 3068d1897445701a7023606a8c708095803301b6 Mon Sep 17 00:00:00 2001 From: Dieter Plaetinck Date: Sun, 26 Jul 2009 20:33:18 +0200 Subject: make some seds more robust --- examples/fancy-install-on-sda | 2 +- examples/generic-install-on-sda | 2 +- src/aif-test.sh | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/examples/fancy-install-on-sda b/examples/fancy-install-on-sda index e094c9f..1322231 100644 --- a/examples/fancy-install-on-sda +++ b/examples/fancy-install-on-sda @@ -19,7 +19,7 @@ worker_intro () { } worker_configure_system () { - sed -i 's/HOSTNAME="myhost"/HOSTNAME="arch-fancy-install"/' $var_TARGET_DIR/etc/rc.conf + sed -i 's/^HOSTNAME="myhost"/HOSTNAME="arch-fancy-install"/' $var_TARGET_DIR/etc/rc.conf } # These variables are mandatory diff --git a/examples/generic-install-on-sda b/examples/generic-install-on-sda index d1e79b9..305bc9a 100644 --- a/examples/generic-install-on-sda +++ b/examples/generic-install-on-sda @@ -24,7 +24,7 @@ worker_intro () { } worker_configure_system () { - sed -i 's/HOSTNAME="myhost"/HOSTNAME="arch-generic-install"/' $var_TARGET_DIR/etc/rc.conf + sed -i 's/^HOSTNAME="myhost"/HOSTNAME="arch-generic-install"/' $var_TARGET_DIR/etc/rc.conf } diff --git a/src/aif-test.sh b/src/aif-test.sh index de891a5..e6d1d33 100755 --- a/src/aif-test.sh +++ b/src/aif-test.sh @@ -24,7 +24,7 @@ $test_dir/setup_test.sh || fail=1 cp $test_dir/perform_test.sh /mnt/etc/rc.d/perform_test || fail=1 # make sure the test will run on the target system -sed -i 's#DAEMONS=(\(.*\))#DAEMONS=(\1 perform_test)#' /mnt/etc/rc.conf || fail=1 +sed -i 's#^DAEMONS=(\(.*\))#DAEMONS=(\1 perform_test)#' /mnt/etc/rc.conf || fail=1 # and that /etc/issue won't blank the screen sed -i 's/^H//' /mnt/etc/issue -- cgit v1.2.3-54-g00ecf