I have a code in my bash script
OUTPUT=""yum update
echo $OUTPUT
echo $OUTPUT >> mylogfile
yum updateis a very long command and without my script it always output something to console, but in my script it starts, for the long time nothing outputs and after a while outputs a lof of data.
Is any way in my script to output data as soon as it is available, but not all data in the same time after long waiting?
yum update >&2