On 8/3/2023 7:31 AM, Delany wrote:
Quite honestly this is a horrendous abuse of configuration, not to mention
design and security principles, and thoroughly inelegant.

I 100% agree with you on your assessment of the _implementation_. If you know of a more elegant implementation without writing a plugin, please tell me. Otherwise, it's the fault of Maven to force me to write such an ugly kludge. Maven should provide a simple expression language for setting properties.

From the point of view of the _interface_ (that is, the user's view—the developer using the child POMs), it is very clean and elegant: the presence of a single user property determines whether deployment is enabled or not.

Once I write a plugin that sets properties based upon an expression, we can replace this horrendous implementation while leaving this clean and elegant interface exactly as it is.

It brings to mind a Go proverb "A little copying is better than a little
dependency."

This has nothing to do with dependency. Copying boilerplate to disable deployment would in no way lower the coupling i.e. it would not reduce any dependency in any way.

I've had my say though. If you want to set a property and not have it
inherited in other repos, put it in .\.mvn\maven.config

I don't want to create other files. I want everything in my POM.

Garret


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to