[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

(mutt) move old messages, but what to do when none are found?



Hi,

I have a couple lines in my .muttrc:

###
### Old Messages Save/delete
###
#Tag old messages
folder-hook deleted$ 'push T~r>6m\n'

#Tag 'em, and search em, top of list, first tagged, save, next new
#If there aren't any tagged msgs, it'll save the first in the list
folder-hook !(to-do*|deleted)$ 'push T~r>2w\n/~T\n1\nn\;s=deleted\n\t'

If it finds old messages, it works exactly as expected, moving messages to
=deleted

If it doesn't find any, it will delete the first message in the index.  How
do I get mutt to only act if the tag (~T) matched something?

Mike



Reply to: