What I’d really like to be able to do is
project.getExtensions().all()
like many of gradle’s built in classes. That way I can do something for every extension class created and everyone that will be created.
What I’d really like to be able to do is
project.getExtensions().all()
like many of gradle’s built in classes. That way I can do something for every extension class created and everyone that will be created.
Can you elaborate your usecase a bit? At the only chance I see is to convert it to a map and then iterate over it. BUT this method is internal api and it’s not guaranteed that this won’t change over time.
project.extensions.asMap
I’m planning to create an open source gradle plugin for setting extension properties via command line.
The problem specifically is when to set the extensions. When my plugin is applied, it is too early, as extensions may have not been created. After evaluation may be too late, if the evaluation depended on the value of the property. Upon extension creation would be ideal.