[Xmonad] ShellPrompt completion like dmenus

Tobias Hauth matrix99 at gmx.de
Thu Sep 20 18:00:35 EDT 2007


Andrea Rossato <mailing_list at istitutocolli.org> writes:
> On Thu, Sep 20, 2007 at 03:03:05PM +0200, Tobias Hauth wrote:
>> Hi,
>> Is it possible to have ShellPrompt complete like dmenu does? For example
>> if I type "fire" it should also show mozilla-firefox and not only
>> everything starting with fire... .
> Hi,
> there is a huge difference between dmenu and ShellPrompt, afaik:
> ShellPrompt gets the completions from bash (or readline in version
> 0.3), whereas in demnu you need to provide them when launching dmenu,
> right?
> Now, having ShellPrompt complete "mozilla-firefox" for "fire" requires
> loading ALL binaries' names present in you path and search them. While
> feasible I think it would be just too much resource consuming.
> BTW you can try it yourself. Attached there's a version of ShellPrompt
> that does what you want (it doesn't require readline): give it a try
> and, please, report back you impressions.

I tried it and I love it. It's much faster than dmenu on my computer and
I notice no slowdown on my laptop (1.86 Ghz Centrino).

If it is to slow for other computer I propose that at least the
.xmonad_history could be used with this kind of completion.

Thanks a lot for this patch (I have to learn haskell)

More information about the Xmonad mailing list