Rsync --progress from within a shell script??

I have a shell script calling for rsync with --progress option. When it runs the file transfer completes but the output of the progress is not shown.

Is there a way to direct the output to the ssh session from within the shell script??

Thanks
 
Code:
if [ -z $TERM ]
then
# if not run via terminal, log everything into a log file
main_function 2>&1 >> /var/log/script.log
else
# run via terminal, only output to screen
main_function
fi

asked and answered.
 
Back
Top