I’m happy to announce the immediate availability of the PomChecker suite! What is it you ask? It’s a small set of utilities to verify that a POM or BOM file complies with the minimum requirements for being uploaded to Maven Central. I wish an utility like this existed years ago when I started publishing artifacts to Maven Central. It took me a few tries in the beginning to get the POM files just right. Recently I’ve seen other developers struggling with these rules as well. Hopefully these utilities can help them and others get on the road much faster.
There are 3 flavors for using PomChecker at the moment:
- Apply it as an enforcer rule with the maven-enforcer-plugin.
- Apply it as a plugin on your Maven build.
- Run it as an external plugin on a POM file.
The last usage is the one that lets you verify POM files that were generated with tools other than Maven. Say you have access to a POM file and you’d like to verify it. Well, there’s no need to edit the file, simply invoke the pomchecker-maven-plugin on the command line by passing the full GAV coordinates plus the goal you want, for example
As always, feedback is welcome. Please feel free to open a ticket at the issue tracker if you find a missing feature or a bug.
Keep on coding!