Hello everyone, I have a question regarding the pr...
# community-support
y
Hello everyone, I have a question regarding the project.rootDir. My project setting is like this
Copy code
rootProject/
| - subproject1/
    | - build.gradle
    | - config.gradle
| - sub/project2/
    | - build.gradle
    | - config.gradle
| build.gradle
| config.gradle
| settings.gradle
| scripts/
| gradlew
| ...
In subproject build.gradle file, it starts with
Copy code
buildscript {
    apply from: 'config.gradle' // the ./config.gradle will point to root project config.gradle with relative paths
    ...
}
And there is a common helper script for setting the project that will be downloaded to scripts/ and refered in the root config.gradle file as
Copy code
project.ext.helperscript = "$project.rootDir/scripts/helper.gradle"
// some logic here to throw error if file doesn't exist
apply from: "$project.ext.helperscript"