Random Mutt Patches

Info

This page contains some random trivial patches to Mutt... use them at your own risk.

Add Forward Delimiters

This patch allows customization of the headers and footer respectively prepended and appended to the body of messages that are being forwarded. It adds a couple of configuration variables, that use the same format of $index_format. The following example reproduces the default behavior.

set forward_intro="----- Forwarded message from %f -----\n" set forward_trailer="\n----- End forwarded message -----"

Postpone Tag Failure

This patch makes the <tag-prefix> not fail immediately, but only after the following command has been entered. This can be useful to automate some things independently from the fact that there are tagged messages or not. See the following patch for an usage example.

Add Close Hook

This patch adds support for an hook on folder close. It gets called both when closing Mutt and when switching between folders; if the hook uses push the pushed commands are executed on the old folder. The example below allows the deletion of messages older than one month (something pretty close to that could have been achieved using a folder-hook, but in that way the message line could have been modified by the executed commands.) Uses the previously introduced $postpone_tag_failure option.

folder-hook . "set postpone_tag_failure=no" folder-hook "=lists/.*" "set postpone_tag_failure=yes" macro index O "T~d>1m^J;d" close-hook "=lists/linux/kernel" "push O"

Last Updated November 10th, 2008