start | find | index | login or register | edit
Montag, 11. März 2002 link aYago

santa VIM is coming to town
transparent integration between vanilla and VIM

vanilla-vim small

[ brought to you by rainman tsr and earl ]


quick summary: the picture shows a vanilla posting (called a snip) beeing remotely-edited in my favorite editor, the VIM. vanilla is running on a server far away, the editor runs on my local desktop. this was inspired by the maxime: editing in a browser is cool, editing in a good editor is even cooler.

if one can get the latter without sacrificing the advantages of the first, i'd call this a "win-win". the glueing is done via XML-RPC using rebXR for REBOL.

this remote-editing thingie (vanilla-vim) was implemented by the great rainman tsr. w/o his rapid-devel skills, there would be no vanilla-vim today.

the (not so) gory details: yep, vanilla-vim is the beasts name. after henso is hard-working on augmenting moz's composer with xml-rpc, time seems right to show vanilla-vim. brain-dead simple but really cool, transparent integration between VIM and vanilla.

using vanilla-vim, one can simply edit a snip in a vanilla space by typing :e vanilla://lcom/chris - then go on editing, copy/paste/move, use the power of the vi. wanna do a quick "publish" (also known as save)? do as you would save a normal text file (eg. by typing :w). vanilla-vim transparently enables this fun :)

it still has its rough edges, but it is another powerful proof of concept.

technical pornography: vanilla-vim is a quite simple multi-level glueing thing. vim6 brought the "netrw" capabilities, which enables "transparent" editing over a network.

the scenario is quite simple: "netrw" allows plugins to register for handling certain url schemes. of course there are plugins ready to handle http://, scp:// and all the other common stuff. but by registering a new url-scheme, one is able to glue VIM to other systems.

the hard work is done by external tools. the vim netrw lib simply dispatches the url schemes to a plugin and the plugin normally calls the right external tool (eg. :e scp://user@host/path/to/file leads to a callout to "scp" which is used to transfer the remote file to a local, temporary location. when the user saves, the local file is sync'd back).

in vanilla-vim's case, the external tool is a rebol script which consists of two major parts:
it maps space-shortcuts (esa) to URLs for their according xmlrpc interface (shhhh ;) and it is able to GET and PUT a snip from resp. to a space (via XML-RPC of course).

on the server side lives the xmlrpc space accessor which maps xmlrpc calls to calls to the local vanilla space library.

that's all there is, but it is fun already :)

vanilla-vim: designed by earl, written by rainman tsr


Anonymous Coward 8288 days ago:
YES! YES! YES! - That's it... nothing else than technical pornography. (quoted from earl!)

Would a sane person use XML-RPC to do that? No! - Would anyone try to use VI? No!

Would any sane person try to use Emacs and HTTP-Post? Yes!

Well... you get it... :-)

andi 8287 days ago:
yeah! that should also work with my favourite CREdit, some WSH-scripting and vanilla-CGI "get-raw/post-raw"

thanks for the ideas!

Please log in (you may want to register first) to post comments!

powered by vanilla
echo earlZstrainYat|tr ZY @.
earl.strain.at • esa3 • online for 8662 days • c'est un vanilla site