D.3 Refiling from the command-line

If you want to refile a lot of messages, a powerful way is to use some of mu’ command-line utilities.

For instance, to move all message from 2010 to some maildir /archive-2010, you could try something like:

$ mu find date:2010..2010 --exec 'echo' | \
     xargs -I {} echo "mu move {} /archive-2010"

(this ^^ just echoes, use to test first...).