On Mon, Nov 24, 2008 at 12:49 AM, Paulo Tanimoto <[EMAIL PROTECTED]> wrote: > > Hi there, > > I'm interested in contributing to yi, and was excited to see the > thread started by Aleks regarding ghci. Somewhat related to his > question, is there an easy way to run functions I define via the > minibuffer? > > Jean-Philippe posted a blog article explaining how to do it by binding > a function to a shortcut [2], but I thought it would be cool to do > that through M-x or :yi. There's a page mentioning that, but > unfortunately it seems to be a bit outdated [1]. > > Looking at this, it seems that I need to do something to put the > function in scope. > >> executeExtendedCommandE :: YiM () >> executeExtendedCommandE = do >> withMinibuffer "M-x" (\_ -> getAllNamesInScope) execEditorAction > > Could anybody give me some directions?
There is a field in the Config, publishedActions, that contrains the list of everything that is available. You can see its default value in Yi.Main. > -- > > Some comments: > > 1. The blog entry [2] uses "modifyLines", but it seems to me that that > has been replaced by "mapLines". Can we update that to avoid > confusion? I'll send a patch. Thanks! > 2. Related to the blog entry, I noticed that at least here on vty, > ctrl-> doesn't seem to work. I'm aware of issues with vty, but > wouldn't it be worth using a different key binding in the article, > then? vt100 and friends offer bad support for this indeed. I tried to fix the issue as you suggest, please see my latest patch. > 3. I need to check if this is a known issue, but if I split the > editor, the top window has its minibuffer appearing in the middle of > the screen, not at the bottom. Should I file a bug for this? Not necessary. It's maybe peculiar behaviour, but it has its benefits. Thanks for the comments! -- JP --~--~---------~--~----~------------~-------~--~----~ Yi development mailing list [email protected] http://groups.google.com/group/yi-devel -~----------~----~----~----~------~----~------~--~---
