Brian’s Stuff

Stuff I don’t want to forget (again!)

Enforcing consistent coding styles with Eclipse and Checkstyle

I use CheckStyle to enforce a consistent coding style on my projects.

There are two plug-ins that I know of for Eclipse that will highlight violations while you work on the code. I started out with Marco van Meegan‘s Checkeclipse Plugin, which I will refer to as Checkeclipse. Nowadays I use David Schneider’s Eclipse Checkstyle Plug-in, which I will refer to as Eclipse-CS. 

The switch was accidental and happened as the result of a bad communication on my part. I told a new hire to install the plug-in but didn’t give them the URL. When I checked back later I discovered they had found they had installed Eclipse-CS.

There wasn’t much difference in terms of the functionality of between the two plug-ins. But Eclipse-CS was available from an Eclipse update site. That made it easier to get it installed but I still felt no need to switch over the whole team en masse. So new hires got Eclipse-CS while the old timers stayed on Checkeclipse until they got a new machine.


Tagged as , + Categorized as Development, Style

Leave a Reply