Penguincoder, 1 year ago (edited 11 months ago) Your request goes against the unix philosophy. Grep does one thing and does it well. If you desire additional functionality, you should add another utility to accomplish what you want. rsync -naP --exclude-from=rsync-homedir-local.txt /home/$USER/ $BACKUPDIR/ | grep denied In your specific task, utilize bashims to do (what I think) you want: rsync -naP --exclude-from=rsync-homedir-local.txt /home/$USER/ $BACKUPDIR/ || echo “task failed”
Your request goes against the unix philosophy. Grep does one thing and does it well. If you desire additional functionality, you should add another utility to accomplish what you want.
rsync -naP --exclude-from=rsync-homedir-local.txt /home/$USER/ $BACKUPDIR/ | grep denied
In your specific task, utilize bashims to do (what I think) you want:
rsync -naP --exclude-from=rsync-homedir-local.txt /home/$USER/ $BACKUPDIR/ || echo “task failed”