On Wed, Apr 07, 1999 at 10:02:09PM -0500, Tim Walberg wrote:
> On 04/07/1999 16:10 -0700, Daniel Eisenbud wrote:
> >> On Wed, Apr 07, 1999 at 06:48:36PM -0400, Jailbait <[EMAIL PROTECTED]>
>wrote:
> >> > Is there any way to get the mailboxes directive to take a wildcard?
> >> > I have something like 100 mailboxes in my listmail directory and I don't
> >> > want to have to list each of them by hand, esp. as new ones get added.
> >> >
> >> > The fine manual doesn't mention wildcarding in the mailboxes directive
> >> > section, nor in the mailboxes shortcuts section.
> >>
> >> Mutt doesn't support this directly, but you might be able to do
> >> something like:
> >> mailboxes `ls -d $HOME/listmail/*`
>
> Here's what I use - I haven't run into any line length limitations (or any other
> type of problems) yet, but I've got <50 folders... The tr and print steps may
> be unnecessary - I forget why I put them in there... But otherwise, this works
> well for a hierarchy of folders.
>
> mailboxes ! \
> `/bin/ksh -c "(/bin/find ~/mail/folders -type f -print | /bin/sort | /bin/tr
>'\n' ' '; print)"`
This is what I use (some more handy things in here perhaps :)
--- .muttrc fragment
source ~/mutt.lists|
set ignore_list_reply_to
source ~/mutt.mboxes|
--- mutt.lists
#!/bin/sh
cd mail
echo -n lists
for d in `cut -f1 -d'@' ~/.lists`
do
echo -n " $d"
done
echo
--- mutt.mboxes
#!/bin/sh
cd mail
echo -n mailboxes
for d in * zolder/*
do
echo -n " =$d"
done
echo
Why the fuss, you say? Well.. this .lists file is also in my QMAILMFTFILE
env.variable, which means qmail-inject will send my Mail-Followup-To to these
mailinglists when I mail to any of them.
For the mboxes thing, most of my mboxes are in fact Maildirs so a recursive solution
would require filtering out anything called tmp new or cur.
Hmm i suddenly see a possible optimization in mutt.lists.. but who cares :)
Greetz, Peter
--
| 'He broke my heart, | Peter van Dijk |
I broke his neck' | [EMAIL PROTECTED] |
nognixz - As the sun | Hardbeat@ircnet - #cistron/#linux.nl |
| Hardbeat@undernet - #groningen/#kinkfm/#vdh |