summaryrefslogtreecommitdiffstats
path: root/bin/etc-update
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2008-10-10 22:02:15 +0000
committerMike Frysinger <vapier@gentoo.org>2008-10-10 22:02:15 +0000
commit44b31cc1d053d427591155a57bc091de907723f2 (patch)
tree002617d4a882187fe6628851a42521fee603fbd2 /bin/etc-update
parentb5ee267fa3533f3f8a1b8010f25f1312eba3bb2e (diff)
downloadportage-44b31cc1d053d427591155a57bc091de907723f2.tar.gz
portage-44b31cc1d053d427591155a57bc091de907723f2.tar.bz2
portage-44b31cc1d053d427591155a57bc091de907723f2.zip
only use dummy echos in do_file() when running in interactive mode
svn path=/main/trunk/; revision=11673
Diffstat (limited to 'bin/etc-update')
-rwxr-xr-xbin/etc-update5
1 files changed, 3 insertions, 2 deletions
diff --git a/bin/etc-update b/bin/etc-update
index ff1378f63..cb58d13f1 100755
--- a/bin/etc-update
+++ b/bin/etc-update
@@ -227,7 +227,8 @@ read_int() {
}
do_file() {
- echo
+ interactive_echo() { [ "${OVERWRITE_ALL}" != "yes" ] && [ "${DELETE_ALL}" != "yes" ] && echo; }
+ interactive_echo
local -i my_input
local -i fcount=0
until (( $(wc -l < ${TMP}/files/${input}) < 2 )); do
@@ -296,7 +297,7 @@ do_file() {
break
fi
done
- echo
+ interactive_echo
rm ${TMP}/files/${input}
count=${count}-1
}