spotbugs

Static analysis tool for finding bugs in Java programs

brewmacoslinux
Try with needOr install directly
Source

About

Tool for Java static analysis (FindBugs's successor)

Commands

spotbugs

Examples

Analyze a compiled Java class file for bugs$ spotbugs -textui MyClass.class
Analyze a JAR file and generate HTML report$ spotbugs -html -output report.html myapp.jar
Analyze a directory with specific effort level$ spotbugs -textui -effort:max build/classes/