excluding files from tar

For the website I work on for my company I have a very large number of files in a single folder that is strictly data for the clients and not data I have to regularly modify.  So when I’m doing a tarball/gzip of my files on the server I need to exclude that folder and all it’s subfolders from the process, here it is:

~# tar -czf /home/test/download.tgz ./ --exclude="*/events/auto/*" --exclude="*/images/waveforms/*"

Till Next Time

Tags: , , , , , ,

Leave a Reply