Re: 'all' folder msgs from last 3 weeks; of symlinks?

2022-09-13 Thread Ralph Corderoy
Hi Tom,

> I have many nmh folders, that get filled by procmail. I'd like to have, an 
> 'all'
> folder that is built by a shell script that could be called by cron daily. 
> I'd be happy, with all msgs, say from the last 21 days. Perhaps this script
> would remove bad symlinks in 'all' each time it runs.

You're implying you want the ‘files’ in +all to be symlinks rather than
hard links?  refile(1) can make hard links with -link.

I'd have thought useful parts would be:

rmf +all
folder -create +all

folder +foo && pick -list -after -21 | xargs -rd\\n refile -link +all
folder +bar && pick -list -after -21 | xargs -rd\\n refile -link +all

sortm +all

If you want symlinks and you want to preserve +all from one run to the
next but remove the symlinks to files which are now too old whilst
adding those which are new then comm(1) would be handy.

> **In this way I could use sort and 'scan' to list the nmh 'all' folder
> msgs sorted by time.**

One has wondered about the separation of email files into folders and
sequences, the overlap between the two, and most commands only working
within a single folder.

-- 
Cheers, Ralph.



Re: 'all' folder msgs from last 3 weeks; of symlinks?

2022-09-13 Thread Conrad Hughes
> I have many nmh folders, that get filled by procmail. I'd like to
> have, an 'all' folder that is built by a shell script that could be
> called by cron daily.  I'd be happy, with all msgs, say from the last
> 21 days.

Install mairix.  Then

  mairix d:21d-

will fill your +s (or whatever you choose to call it) folder with
symlinks to emails from the last 21 days.  It'll do a whole lot more
though since it's a general search engine.  It can even index compressed
.mmdf archives: it's *great*.

Conrad



'all' folder msgs from last 3 weeks; of symlinks?

2022-09-13 Thread Tom R
I have many nmh folders, that get filled by procmail. I'd like to have, an 'all'
folder that is built by a shell script that could be called by cron daily. 
I'd be happy, with all msgs, say from the last 21 days. Perhaps this script
would remove bad symlinks in 'all' each time it runs.

**In this way I could use sort and 'scan' to list the nmh 'all' folder msgs 
sorted by time.**

Has someone already done this or the equivalent? Ideas/comments?

--
thanks,
Tom