[Haddock] vim help text export

Lars Krueger lars_e_krueger at gmx.de
Sun Jan 15 12:26:12 GMT 2012


Hi,

I'm trying to implement an exporter to vim help text format and I have a few questions. Maybe you guys can help me out on these.

David Waern suggested I should do this in a separate program due to maintenance issues. My first try was to read all .haddock files from the .cabal and /usr/share directories and generate the docs from it. 

Q1: It seems the InstalledInterface instances do not contain the actual documentation, just general info. For instance, hmi_description returns Nothing for most, if not all, modules. I concluded the InstalledInterfaces are meant for regenerating the table of contents files. At least the XHtml backend only uses them that way. Is this assumption correct?

Q2: I get a lot GHC internal modules, even with filtering by OptHide. I took the code from the render function of haddock. Since the package version matches my installed ghc-7.0.4, it's not a stale file or something. Is there another criterion besides OptHide to filter out those modules from the index?

Q3: How do I test an actual haddock run like cabal does it?

Q4: If my assumption in Q1 is correct, my separate program will be a stripped-down version of haddock's Main module. The only change/addition will be another call to my backend. I fail to see how this will reduce maintainance efforts. What do I miss here?

Thanks in advance.
-- 
Dr. Lars Krueger


Empfehlen Sie GMX DSL Ihren Freunden und Bekannten und wir
belohnen Sie mit bis zu 50,- Euro! https://freundschaftswerbung.gmx.de



More information about the Haddock mailing list