Nicolas --

...and then Nicolas Rachinsky said...
% 
% On Sun, Dec 09, 2001 at 06:26:56AM -0500, David T-G 
<[EMAIL PROTECTED]> wrote:
% > Hmmm...  Not for moving stuff out; grepmail will do a good job of finding
% > the messages but that doesn't help you empty the big box.
...
% 
% I think grepmail is the tool I need, thanks.
% 
% Something like: 
% grepmail -v -d "before `date -v -2w '+%Y-%m-%d %H:%M:%S'`" mbox >new
% grepmail -d "before `date -v -2w '+%Y-%m-%d %H:%M:%S'`" mbox >old
% seems to do what I want.

Oh, of course :-)  I haven't used grepmail enough to have realized it had
a -v flag.


% 
% Now I have to do compressing, uncompressing, appending, locking and ...

That's easy:

  mutt_dotlock source_file
  mutt_dotlock archive_file
  grepmail -d "before date..." | gzip -9 >> archive_file
  grepmail -v -d "before date..." > tmpfile
  mv -f tmpfile source_file
  mutt_dotlock -u archive_file
  mutt_dotlock -u source_file

gzip can append :-)


% 
% Nicolas 


:-D
-- 
David T-G                      * It's easier to fight for one's principles
(play) [EMAIL PROTECTED] * than to live up to them. -- fortune cookie
(work) [EMAIL PROTECTED]
http://www.justpickone.org/davidtg/    Shpx gur Pbzzhavpngvbaf Qrprapl Npg!

Attachment: msg21356/pgp00000.pgp
Description: PGP signature

Reply via email to