Is it possible to set/override plugin configuration from a command line?

I would like to be able to set (or override) a specific configuration property for a plugin. For example:

pitest {
    threads = 2

and with something like:

gradle pitest -Pplugins.pitest.threads=4

change a number of used threads for this specific run.

Is there available a mechanism similar to which would allow to do it without manual parsing parameters passed to Gradle with -P?

1 Like

No, there isn’t currently such a mechanism. We certainly want to offer this at some point, but it’s surprisingly difficult to implement well.

Digging it out. Is is currently possible in Gradle?

I found it very useful to have different behavior on a developer station and CI server and keeping locally uncommitted files is asking for trouble (while using a gradle relase plugin even harder). Writing custom logic in a plugin to check available properties doesn’t sound good, especially in a case I would have to convince other plugin’s author to do that :).