Incremental Backup shell script.
I've written a shell script to make incremental backups and have a question about flags to tar.
here's an exerpt. variables are set earlier in the script
echo "Saving files from web directory"
# this tars up my web directory into web.tar.gz tarball.
/bin/tar -czf $TMP$WEB_FILENAME --after-date=$LAST /var/www/htdocs
The script works fairly well, but the resulting archives contain a lot of empty folders in addition to the folders containing the files that have been changed since the last backup. What flag, if any could I add to this line to have the empty folders not be included in the archive.
|