[Haskell-cafe] Re: MUA written in Haskell (was: Getting GHC to print "Done" when it's finished linking?)

Brian Hulley brianh at metamilk.com
Wed Mar 8 14:52:28 EST 2006


Nils Anders Danielsson wrote:
> On Tue, 07 Mar 2006, "Brian Hulley" <brianh at metamilk.com> wrote:
>
> (Moved from ghc-users.)
>
>> Brian Hulley wrote:
>
>> (time for a proper email client to be written in Haskell! ;-) )
>
> I had the same thought yesterday, after an Emacs-Lisp session in which
> I was trying to get Gnus to do exactly what I wanted it to...
>
> Out of curiosity, how much work would it take to write an easily
> configurable, decent MUA in Haskell? I don't know too much about MUAs,
> but I have a feeling that we already have quite a few libraries that
> are needed for the job: UIs (including HTML rendering...), plugins,
> various protocols, encryption...

I'm afraid I don't know much about MUAs either.
I see there's some stuff in Network.* that may be useful...

Unfortunately I don't have time at the moment to try implementing one, but 
for what it's worth here are some thoughts I had on what an "ideal" email 
client, suitable for Haskell programmers, would be like:

1) Plain text based to avoid problems with viruses etc getting in via HTML. 
HTML emails received could just be displayed as plain text (including all 
markup)

2) "What-you-see-is-exactly-what-will-be-sent" for editing, so that when you 
press "send" you don't need to worry about the text being all mangled up by 
wrapping/replacement of characters etc

3) When you click "reply" or "reply all", the original text should be 
indented with '>' (at the moment OE requires QuoteFix to achieve this 
trivial but essential functionality)

4) An API could be exposed then the user could write scripts to put things 
into correct folders etc.
The API could provide info about what is currently waiting on the server, 
and the ability to download or delete without downloading (eg for big 
attachments that are suspected of being viruses)

5) Ideally the scripting language would be Haskell. There is already stuff 
in Language.Haskell.* for doing parsing but I can't find anything which 
would allow you to compile and load functions into a running program.

So I'd imagine that the email client would contain a plain text editor that 
wrapped text as it is edited (if wrapping is needed nowadays anyway?) with 
email addresses and URLs in the text clickable; a tree of folders and a 
folder contents window which could display the emails by date/subject/name/ 
or thread; and an API and way of loading scripts written in Haskell to do 
all the complicated automatic stuff - which would now be completely under 
the user's control.

Regards, Brian. 



More information about the Haskell-Cafe mailing list