On Wednesday 26 June 2002 03:55 pm, Gray, Jeff wrote:
> I've been contemplating hacking together some sort of Gvim-based
> interface to the Ruby debugger, sort of a mini-IDE I suppose, that
> would do the following, as a start:
>
> * Use a split window to display code above, ruby debugger
>   interface below
> * Do some pre-formatting and apply syntax highlighting to the
>   debugger I/O (useful for "p"'ing deeply hierarchical objects)
> * Synchronize current file/line in the code window to the debugger
> * Define commands/keystrokes in the code window to do things
>   like set breakpoint at current line, etc.
>
> I'm by no means an expert with Vim scripting, but Vim features like
> :Explore make me think it's a feasible project.  Please let me know
> any productive comments -- pointers to existing work, suggestions
> to alternatives, public demand for such a project, etc. -- that you
> might have.

Hi Jeff,

I've been thinking about this (for both Ruby and Perl). The main 
problem is that you have to have an external connection to the 
debugger, since the internal Vim environment is strange enough you 
don't want to run a debugger in it (and as was noted, most Vims 
aren't compiled with Ruby for some reason).

The built-in debugger interface is pretty specialized, and hooks into 
the main event loop of Vim (and only works with X).

I don't know if you want this to work under Windows, but it's possible 
(I think) to use named pipes in both the Unix and Windows envronment 
(at least Windows/NT; don't know if you can do this with 
DOS-windows).

So you could whip up a version of debug.rb that talks to a couple of 
named pipes, and then open a connection to those pipes from Vim. One 
would pass commands from Vim to the debugger, and another would pass 
output and line number data to Vim.

I don't know how easy it would be to interrupt a running program, 
though.

-- 
Ned Konz
http://bike-nomad.com
GPG key ID: BEEA7EFE