dinfo print only when verbose defined
authorAndreas Thienemann <andreas@bawue.net>
Wed, 20 May 2009 10:30:22 +0000 (12:30 +0200)
committerHarald Hoyer <harald@redhat.com>
Wed, 20 May 2009 10:30:22 +0000 (12:30 +0200)
dracut
dracut-functions

diff --git a/dracut b/dracut
index 1aeb0ad..58c50ec 100755 (executable)
--- a/dracut
+++ b/dracut
@@ -96,7 +96,7 @@ hookdirs="pre-udev pre-mount pre-pivot mount"
 readonly initdir=$(mktemp -d -t initramfs.XXXXXX)
 trap 'rm -rf "$initdir"' 0 # clean up after ourselves no matter how we die.
 
-export initdir hookdirs dsrc dracutmodules modules debug
+export initdir hookdirs dsrc dracutmodules modules debug beverbose
 
 # Create some directory structure first
 for d in bin sbin usr/bin usr/sbin usr/lib etc proc sys sysroot dev/pts; do 
index 51dd29f..2beaef2 100755 (executable)
@@ -33,7 +33,7 @@ dwarning() {
 }
 
 dinfo() {
-    echo "I: $@" >&2
+    [[ $beverbose ]] && echo "I: $@" >&2
 }
 
 derror() {