[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug-tar] Excluding directories based on content
From: |
Sergey Poznyakoff |
Subject: |
Re: [Bug-tar] Excluding directories based on content |
Date: |
Sun, 19 Nov 2006 21:22:18 +0200 |
Joerg Schilling <address@hidden> wrote:
> > find . -type d -exec test -r {}/FILENAME \; -prune -o -print |
> > tar --no-recursion -cf archive.tar -T -
>
> This does not work.....
It works for me. -exec returns true or false regarding on whether
FILENAME is present in the directory, and -prune makes find to not
descend into that directory.
> find . -type d -exec echo {}/FILENAME \;
>
> will print a "{}/FILENAME" for each directory.
The `echo' command has nothing to do with our question.
Regards,
Sergey
Re: [Bug-tar] Excluding directories based on content, Joerg Schilling, 2006/11/20