I use
tar hczf t.tar.gz * --exclude="./test1"
where test1 is the name of a directory that I want to prevent from being tarred.
Unfortunately, tar still includes the directory test1. How can I have tar exclude directories?
tar
I use
tar hczf t.tar.gz * --exclude="./test1"
where test1 is the name of a directory that I want to prevent from being tarred.
Unfortunately, tar still includes the directory test1. How can I have tar exclude directories?
Best Answer
So it turns out that to prevent the tarring of a directory you need to change where you're adding the --exclude
works