Better to use ls -1. You bypass a lot of fstat() calls when doing the
ls -l, you probably don't need the -a (unless you have boxes that start
with a "."), and by doing ls -1 you bypass the need for the awk command.
ls -1 $HOME/mail/* | grep -v sent
Much better, and more efficient on a large mailbox structure.
On Mon, Apr 02, 2001 at 03:34:51PM -0600, dan radom wrote:
> sorry to reply to my own message, but i think i may have figured it out.
>
> ls -al $HOME/mail/* |awk '{print $9}' |grep -v sent
> produces
> /home/user/mail/inbox
> /home/user/mail/mutt-users
> and so on. is there any reason that i couldn't replace the echo command with the ls
>-al one for my mailboxes directive in .muttrc?
>
> * dan radom ([EMAIL PROTECTED]) wrote:
> > I'm defining mailboxes in ~/.muttrc as follows...
> >
> > mailboxes `echo $HOME/mail/*` /var/spool/mail/graffix
> >
> > ...that works fine for displaying notifications about new messages in those
>folders. the problem is is that $HOME/mail/* includes sent (set record=~/mail/sent),
>and i'd rather not get notifications for new messages in the sent folder. it doesn't
>look like i can replace the mailboxes echo with something like `echo $HOME/mail/*
>|grep -v sent` sa the output of the echo command is all on one line. Is there any
>way to not get notifications of new messages in sent, while not having to specify
>every single mailbox for the mailboxes directive in .muttrc?
> >
> > thanks,
> >
> > dan
>
--
Marius Strom <[EMAIL PROTECTED]>
Professional Geek/Unix System Administrator
URL: http://www.marius.org/
http://www.marius.org/marius.pgp 0xF5D89089 *updated 2001-02-26*
"Never underestimate the bandwidth of a mini-van full of DLT
tapes traveling down the highway at 65 miles per hour..."
-Andrew Tanenbaum, "Computer Networks"