In the religious war between the command line and IDE (integrated
development environment), I’m firmly on the IDE side. Having said that,
there’s no substitute for having a console when working with a dynamic
What I really want is the two combined. I should be able
to set a breakpoint in my IDE and when the breakpoint triggers have access
to the standard IDE inspectors (watch window, local variables, etc.).
But I also want access to a console, so I can do more sophisticated
debugging when needed.
This is pretty obvious stuff – Visual Studio has had a Immediate Windows
for ages where you can poke around the internals or your C++, C#, JScript
or VB program. Borland’s IDE’s had similar functionality, although not
as easy to use.
Yet its strangely lacking in the Ruby community. I’ve tried all the IDEs
– FreeRide, Arachno (my favorite), Komodo, RDT, eric3, etc. None of them
can do it. And really, its not just an IDE thing, my understanding
is that the VIM Ruby integration doesn’t have this either.
So kudos to Sapphire in Steel,
a new plug-in that turns Visual Studio 2005 into a Ruby IDE. The integrated
debugger comes complete with a Ruby console window. When you hit a breakpoint,
the console is bound to the current context. So if your code set a local
variable “foo” to the value 7, just type in “foo” in the console and you’ll
get back 7. You can do pretty much anything you want, including modifying
the local variable.
Nice work – I have high hopes for the future of Sapphire