In Android Studio settings there are two paths for gradle. The first is in project-level_setting called Gradle home:
, and second is Global_level_setting service directory path:
, which I use for offline gradle path.
What is the difference and what exactly is this path for? I googled and could not find a clear answer.
The Gradle user home directory ( $USER_HOME/.gradle by default) is used to store global configuration properties and initialization scripts as well as caches and log files.
Open Preferences -> Build, Execution, Deployment -> Gradle . Select Use local gradle distribution and specify Gradle home .
On android studio just go to File > Settings > Build Execution, Deployment > Gradle > Service directory path choose directory what you want.
The Service Directory Path is the default Gradle Home directory. This is where the cache is maintained.
The Service Directory Path is the default Gradle Home directory. This is where the cache is maintained.
Basically it overrides the default Gradle:Home when entering in offline mode , Gradle will look for dependencies there (in the cache) because it does not have acces to the network ; which is kind of a heatburn if you do that.
NOTE : Gradle home - it is speciffied the fully qualified path to your Gradle installation.
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