From 7fc8cb21f5670065c231eb6711edd88e9616acf6 Mon Sep 17 00:00:00 2001 From: Jeremy Landis Date: Mon, 6 Nov 2023 21:23:46 -0500 Subject: [PATCH] [docs] Per #113, add how to use analysis properties with maven plugin --- README.md | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/README.md b/README.md index bdf588af..c7aa6a2c 100644 --- a/README.md +++ b/README.md @@ -85,3 +85,21 @@ If using groovy with same group id (```org.codehaus.groovy 3.x``` or before or ` ## Eclipse m2e Integration ## The plugin cycles controlled by Eclipse require compilation phase for m2e without further help. This plugin runs verify and during site generation. Therefore Eclipse m2e will show up but not do anything with this plugin alone. In order to have proper execution within Ecipse m2e, use [m2e-code-quality](https://github.com/m2e-code-quality/m2e-code-quality) plugin for spotbugs. + +## Analysis Properties ## + +Is there some way to set the [Analysis Properties](https://spotbugs.readthedocs.io/en/stable/analysisprops.html) when using the maven plugin? + +Analysis properties are passed as Java system properties, so they can be set in the configuration element. + +E.g. to set the findbugs.assertionmethods analyzer property: + +``` + + com.github.spotbugs + spotbugs-maven-plugin + + -Dfindbugs.assertionmethods=org.apache.commons.lang3.Validate.notNull + +```