There are quite a few Haskell compilers/interpreters, and on Windows they all want to be the default handler for .hs and .lhs files. This document prescribes how all the installers should work with regards to file paths. Hopefully this document can reach a concensus.
1 User configuration
During install the user will be asked whether they want to register .hs/.lhs files to open with the compiler being installed. Yes will be the default. If the user picks no, then no changes will be made to the .lhs/.hs association settings.
2 File types
The Haskell file types are given as .hs and .lhs. They icon used shall be the top line of this image. These icons are available in the Hugs CVS repository in Windows .ico format (where?).
The file type description for each file shall be "Haskell Document".
3 Actions available
The actions available for each compiler shall be:
- Open in <interpreter>
Where interpreter is an interactive environment, in the style of Hugs/GHCi/Yhe.
If the interpretter can offer a sensible Edit action (i.e. WinHugs, but not GHCi) then there will be an additional command:
- Edit using <interpretter>
4 Default Action
The default action (double clicking) is ranked with the following priority:
- If prior to installing the compiler there is a default document handler for .hs/.lhs files, which is not one of the compilers adhereing to this standard, then this has highest priority.
- Any Edit action.
- Any Open action.
If there is a preexisting default handler, then that must not be changed without the users consent (a checkbox during install). If the preexisting action is a higher priority than the new one, then this defaults to no, otherwise defaults to yes.
5 New Document Creation
An entry should be added to the Explorer's New menu, giving Haskell Document as an option, which will create a .hs file.
6 Technical Implementation
Not much point in doing this section until everyone agrees on the end user behaviour!