Thursday, 15 August 2013

Sublime Text - creating plugin showing external info with autocomplete from clojure.repl/doc

Sublime Text - creating plugin showing external info with autocomplete
from clojure.repl/doc

Is it possible to somehow augment the autocomplete box by showing another
box with info that gets returned from clojure.repl/doc.
for example if you are interested in the docs for clojure.set/difference
and do the following after running lein repl you get some useful
information.
user=> (use 'clojure.set)
nil
user=> (doc difference)
-------------------------
clojure.set/difference
([s1] [s1 s2] [s1 s2 & sets])
Return a set that is the first set without elements of the remaining sets
My idea is that if the autocomplete suggests 'difference' you then see if
any documentation exists and display what there is. Perhaps it is possible
to somehow connect to SublimeRepl to do this.
Here is an Emacs example of what I am trying to do
UPDATE: There is a python NRepl client here: here. All I now need to be
able to do is get the value of the current autocomplete option and show
the result returned if any.

No comments:

Post a Comment