Further maildir sorting experiments.

Add another sorting method - pass the whole maildir list to a Lua
function as a table and allow it to be sorted entirely in Lua (eg
using table.sort with a custom comparison function).