DEV Community

Discussion on: Gradle plugins and extensions: A primer for the bemused

 
autonomousapps profile image
Tony Robalik

I think that disallowChanges() is more for user-facing API. I do what you're suggesting all the time. E.g., in a task configuration block:

consumerTask.someInputFile.set(producerTask.flatMap { it.someOutputFile })
Enter fullscreen mode Exit fullscreen mode

Those properties aren't meant to be used by users, so if they mess with the properties, that's on them, Undefined Behavior.

Thread Thread
 
martinbonnin profile image
Martin Bonnin

I see, thanks!