When I run this gradle task
-Pcons=value anyTask --stacktrace --info --debug
It executes the build.gradle file. And this file contains the line
apply from:"another.gradle"
In this scenario when I run anyTask, does all the code in another.gradle work? Or is it just accessible?
This is the way how script plugins are apllied. This is how it's described in the official docs.
Script plugins are additional build scripts that further configure the build and usually implement a declarative approach to manipulating the build. They are typically used within a build although they can be externalized and accessed from a remote location.
And
Script plugins are automatically resolved and can be applied from a script on the local filesystem or at a remote location. Filesystem locations are relative to the project directory, while remote script locations are specified with an HTTP URL. Multiple script plugins (of either form) can be applied to a given target.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With