Is it possible to pass null property value in pom.xml?

I have a property that is created like -dVerbose

in a mvn dependency:tree

plugin. It doesn't require any value. If specified, additional work is done in my application tests.

So, in a Maven failover plugin, I would like to either set some value (it doesn't matter which one, but not null ) or set it to null , depending on which Maven profile is active.

I've tried something like this:

<systemPropertyVariables>
    <doNotInsertData>${null}</doNotInsertData>
</systemPropertyVariables>

      

or <doNotInsertData>null</doNotInsertData>

or <doNotInsertData/>

.

But unfortunately all of the above results in null being irrelevant when I run the maven target. Is it even possible to pass null at all using pom.xml?

+3


source to share





All Articles