Q:

Configuring Checkstyle (Java) at a shared location

I have a requirement where I want to configure all rules, suppression, etc. at a shared place and all other users will point to the same location to run the required rules. I have referred to Checkstyle sourceforge site and some other references too, but not able to figure out how. It would be a great help if some pointers are suggested.

A:

It'll largely depend on how you run Checkstyle.
As already mentioned, you can use a build server configured to run Checkstyle—but this has a slight disadvantage that developers will have to check in their code, then wait for the build to kick in before getting any feedback.
On the opposite end, you can use Checkstyle in your IDE, such as Eclipse with the eclipse-cs plugin. The eclipse-cs plugin can be easily configured to use a Checkstyle configuration file on a shared (network) folder, or even on a remote location (a URL).
In our shop, we use Maven + Checkstyle plugin to execute Checkstyle checks as part of the build, whether on the developer's machine or on the CI server. The Checkstyle rules in this case are checked-in as part of the project source (which allows refinement/relaxation of rules on a per project basis). We then configure eclipse-cs to load the "project relative" configuration file and use that. This provides Checkstyle coverage throughout the development, local build/deploy and CI cycle.

