Skip to main content

Software Development

Spring Roo ITD filter plugin for Eclipse Helios

Thanks to a bit of copy-paste from SpringSource Tool Suite and an answer on Stack Overflow, I was able to bash together a little plugin to filter Spring Roo ITD files from Eclipse's Package Explorer and Project Explorer. It's free to use for any purpose as far as I'm concerned, especially because I didn't write any of it. To use it, take the file attached to this story and drop it into eclipse/plugins.

(I probably could have taken the plugin from STS and dropped it into the standard Eclipse but it also has other features that I don't need.)

Gradle and Eclipse WTP - jst.web facet version

As of Gradle 0.9, the jst.web facet version in the eclipse plugin is hard-coded to 2.4. Here's a workaround:

eclipseWtp.whenConfigured { config ->
    config.facets.each {
        if (it.name == 'jst.web') {
            it.version =
                configurations.providedCompile.getAllDependencies().find{
                    it.group == 'javax.servlet' && it.name == 'servlet-api'
                }.version
        }
    }
    config.facets.unique()
}

Note that you'd better declare a providedCompile configuration dependency on javax.servlet:servlet-api or this is going to break. But you'd better do that anyway or your project isn't going to build.

Let me know if you know of a better way to do this.

Answers!, a game of questions

About a month ago, I spent a weekend or two hacking and designing levels for a riddle game on the web. Now that I'm no longer working on it, I suppose I might as well release it; it's as done as it's ever going to get.

It's simple to play: the game presents a clue, you type in the correct answer then move on to the next level. See if you can finish all 20 levels. Check it out here: Answers!, a game of questions.

Perl TDD - Continuous Testing

Now that I've decided to adopt test-driven development and continuous testing for my latest project, which happens to be a daemon written in Perl, I've gotten pretty tired of this cycle:

$ vim t/0020.elephant.new.t
$ prove t
$ vim Elephant.pm
$ prove t
$ vim t/0020.elephant.new.t
$ prove t
$ zzzzz
bash: zzzzz: command not found

To get around this, I've put together a tiny script that will automatically run prove whenever I change any file under the current directory. Now I can run this script in a window on my secondary monitor, use my primary monitor to edit the current test and the current production code, and the whole test suite automatically scrolls past the corner of my eye every time I save. Hurray!

Screenshot:
Terminal showing watch-prove.pl running

Feel free to grab the script (attached to this post) if you'd like to check it out. Since it uses Linux::Inotify2 it doesn't work in any other OS; sorry about that.

SQL formatting and SQL Pretty Print on grr.ca

I wrote a fairly substantial post about SQL formatting and SQL Pretty Print on the unprofessional sister site. It turned out to be slightly less unprofessional than the norm over there. Head on over if you're interested in that sort of thing. If you like the software, though, before deciding to buy a license, keep in mind that the company appears to be unreachable at the moment.

Syndicate content