Next: , Previous: , Up: mairix.el—Mairix interface for Emacs   [Contents]

5 Extending mairix.el

Your favorite Emacs mail program is not supported? Shame on me. But it is really easy to integrate other mail programs into mairix.el. Just do the following:

Write a display function

Write a function that displays the mairix search results. This function will be called from mairix.el with the mail file/folder as the single argument. For example, the function mairix-rmail-display is currently used for RMail and mairix-gnus-ephemeral-nndoc is used for Gnus.

Write a get-header function

Write a function that retrieves a header from the currently active mail. The single argument for this function is a string with the header name. For examples, see mairix-rmail-fetch-field and mairix-gnus-fetch-field for RMail and Gnus, respectively.

Integrate the functions into mairix.el

Add your mail program to the defcustom of mairix-mail-program. Then add the functions to mairix-display-functions and mairix-get-mail-header-functions.

Let me know...

...so that I can eventually integrate it into future versions of mairix.el.

And that’s it!