It’s largely dependent on what is supported by what you’re using that is out of your control. My expectation is that the
release
task is added byorg.some.otherplugin
and that you can’t change its code.
and
Also, the code shown doesn’t really indicate what how
MyCustomClass
andsomeReleaseFunction()
are interacting with therelease
task.
Yes, you are completely right. There is an weaving of a few projects at different levels, and its hard to simplify that into an example I can put on here. There is a particular case, when a specific variable is not set, and that is the failure case I am trying to address.
I just found out about https://docs.gradle.org/4.9/dsl/org.gradle.api.plugins.ExtraPropertiesExtension.html
I just added project.ext.set(keyString, valueString)
before the apply plugin
, it does solve the problem.
Thanks for the help!