* Eric Blau <[EMAIL PROTECTED]> [2002-08-17 15:17]: > I am having a problem getting a folder-hook working properly. > I want mutt to automatically move mail older than 1 month from > my Maildir-format INBOX into an archive mbox-format INBOX.
please put the description of the goal *first* - thankyou. > I have the following folder-hook in my muttrc file: > folder-hook =INBOX 'push T~r>1m\n\;s=archive/INBOX\n' this macro was easier to read if you made it a macro and used the command *names*. > This folder hook seems to be working nicely except that mutt > always moves the last message in my INBOX into the archive > INBOX, even though the message should not match ~r>1m. > Every time I start up mutt, the folder-hook always > moves the last message over to the archive box. > Any ideas why this is happening? "~r" takes *no* argument and is for *all* read messages. i think you want to use "~d" which takes a date range as an argument. here's the macro way: folder-hook =INBOX 'macro index ,, \ <tag-pattern>~d>1m\n<tag-prefix><save-message>=archive/INBOX\n' advantage: you issue the command, so you know what and when it's happening. apply when necessary. you can leave out the last "\n" so you can still back out with CTRL-G if you issued the command accidentally. > Should I send a flea? no! scratch yourself on the head instead. ;-) Sven [damn - there goes another smiley from my supply]