Monad Hosting Part II -- Stop acting like cmd.exe!
Travis recently posted a good comment:
… I would *love* to be able to configure Monad’s tab completion behavior! …
So would we.
Tab completion is just one of the many things that would be great to change about the default Monad console host. Other things that drive us crazy are the lack of standard CUA bindings (ie: Copy, Paste, keyboard-based selection,) and full Unicode support, to name a few. It’s comes down to a matter of priority.
As I mentioned in an earlier post, Monad can be hosted by any managed application that wishes to do so. Hosting applications need only to implement a fairly simple interface in order to host the engine. Our default host, msh.exe, owes nearly all of its functionality to the fact that we use the same infrastructure that cmd.exe does. With relatively little code, we get passable tab completion, history cycling, and a bevy of function keys that are pretty useful. Changing any of this means writing huge gobs of code.
We did write some special code to tab-complete cmdlet names, but that was a fairly isolated change.
For this release, we’ve focused our effort on really fleshing out the underlying Monad engine, APIs, and infrastructure. These are the things that hurt the most when they are missing, and ultimately empower many, many more of you. Writing a more functional host is on our list of things to do in a future version.
That said, this is the type of thing that the Monad community could easily astound us with. Several BetaPlace members started writing a GUI host during our much earlier betas, but I haven’t seen much activity on it lately. A Microsoft empoyee wrote a neat WinForms application that hosts Monad in a tabbed interface. Do you want transparency? Tabs? Background images? Awesome tab completion? Go for it! Our team (via the BetaPlace newsgroups) loves to help, should you want it or need it.
[Edit: Monad has now been renamed to Windows PowerShell. This script or discussion may require slight adjustments before it applies directly to newer builds.]