Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Difference between Gradle home directory and Gradle offline directory

Tags:

android

gradle

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.

like image 654
Mahdi Avatar asked Dec 12 '15 10:12

Mahdi


People also ask

What is Gradle home directory?

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.

Where is my Gradle home?

Open Preferences -> Build, Execution, Deployment -> Gradle . Select Use local gradle distribution and specify Gradle home .

How do I change the home directory in Gradle?

On android studio just go to File > Settings > Build Execution, Deployment > Gradle > Service directory path choose directory what you want.

What is Gradle service directory path?

The Service Directory Path is the default Gradle Home directory. This is where the cache is maintained.


1 Answers

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.

like image 85
maspinu Avatar answered Oct 12 '22 12:10

maspinu