Ext Properties set in beforeEvaluate are overwritten by empty map

Hello, in the rootProject I set properties that are required by all subprojects. Now I need it in an early phase so I tried to set my extra properties in subprojects.beforeEvaluate like below. But it seems that they are overwritten by an empty map later on so the extra properties are missing in all subprojects. With println I can see thy were attached in the first place. But once I print them in the projects configuration phase there is only [:] attached as project.ext.properties. Thanks, David

subprojects {
  beforeEvaluate {project->
    project.ext.modules = rootProject.ext.modules

sorry my fault, solved it already.

Please tell us how