Hello, The command in your case should be: find $HOME/Maildir -type d -path *cur* -prune -o -path *new* -prune -o -path *tmp* -prune -o -path *courierimapkeywords* -prune -o -print I hope this will help you. Best Regards, I.Petrov On 12/29/2014 06:42 PM, Hylton Conacher (ZR1HPC) wrote:
Hi,
I am endeavouring to print a list of my Maildir folders to a file so that I can use that same list when I construct a Procmailrc file.
Initially I ran ~> find $HOME/Maildir -type d -print | sort > /home/hylton/maillistdir
**sample snip*** /home/hylton/Maildir/.INBOX.A-F.Bookstores.Kalahari /home/hylton/Maildir/.INBOX.A-F.Bookstores.Kalahari/courierimapkeywords /home/hylton/Maildir/.INBOX.A-F.Bookstores.Kalahari/cur /home/hylton/Maildir/.INBOX.A-F.Bookstores.Kalahari/new /home/hylton/Maildir/.INBOX.A-F.Bookstores.Kalahari/tmp ********
I noticed that there were many sub-folders I did not need. Given this list ended up being 273pg, after a short stint at editing it I decided there had to be a way to exclude certain folders.
What I need is the namesand paths of the folders ie /home/hylton/Maildir/.INBOX.A-F.Bookstores.Kalahari
, not the /cur, /tmp, /new or even the /courierimapkeywords sub-folders.
So far I have:
~> find $HOME/Maildir -type d \( ! -name tmp \) -o \( ! -name cur \) -o \( ! -name new \) -o \( ! -name courierimapkeywords \) | -print | sort > /home/hylton/maillistdir
The above command returns a 'Command not found' in my destination file of maillistdir.
I have RTFM'd, Googled and still cannot find an example of what I want to do. I even visited the sites Aaron Digulla gave me on an earlier pointing to the complexities of find.
Any more help appreciated
Tnx Hylton -- To unsubscribe, e-mail: opensuse+unsubscribe@opensuse.org To contact the owner, e-mail: opensuse+owner@opensuse.org