I want to include and exclude folders from directory listing, say I have
following folders:
Abc/workspace
Def/workspace
Ghi/workspace
Jkl/workspace
Mno/workspace
And so on
I want to generate a tar file for the above folders but wants to exclude all
“workspace” folders, I tried like this:
<tar destfile="archive_${KILLME}.tar" >
<tarfileset dir="${base.dir}">
<filename name="jobs/"/>
<not>
<filename name="jobs/**/workspace/"/>
</not>
</tarfileset>
</tar>
But it takes forever to generate tar file because each of “workspace” directory
conatins huge data and these are the folders I want to exclude in my tar file.
Any idea where I am wrong or any thoughts should I do to resolve this issue.