Eclipse Text Editor Extension Plugin

17 May 2007

I've been ripping through lots of code refactoring and cleaning, so I've been dying to script up a few of these basic text manipulations, but Eclipse doesn't really have much to help there. I went searching, and found the Eclipse Text Editor Extension plugin. It's really basic, but its most useful feature is the "Filter..." functionality. It lets you select a chunk of code, and run any shell commands on that code as a filter.

This is great! It opens up all sorts of possibilities which you'd have using lesser plain text editors like vi.

My first application of this excellent little plugin was to hack up a quick little Perl script to wrap SQL code in Java string literals. I've been doing lots of this by hand, but no more! Cygwin and some PATH hacking make this especially useful on Windows.

I've recently begun recognizing the value of shortcut keys, so I'm pleased to see that I can quickly get to the filter dialog by pressing Alt-Shift-|(pipe).

Filed Under: Work Linux Computers Java