[Haskell-cafe] Emacs script to align Haskell import list
chrisdone at googlemail.com
Sat Jun 26 06:25:53 EDT 2010
I whipped up a little Emacs script to align the import lines in the
current buffer. I am using it in my projects and have experienced no
problems. It's good at keeping within 80 columns.
I've pasted it as a gist on Github so that anyone can edit it, gists
also provide a simple revision history and comment support. Please
feel free to contribute some tweaks and fixes. I'll then see about
merging this into haskell-mode in some fashion.
It doesn't handle multiple line explicit imports as I have a personal
rule that any explicit import list with more than a few symbols should
be changed to an "as X" import, as an addition to tibbe's style
I haven't decided on a recommended keybinding. I'm considering a
context-dependent binding of C-c C-. that indents the import list when
you are on an import line.
More information about the Haskell-Cafe