I use the windows system,and I find after I install Android Studio,it will create the folder .gradle in my system disk,and this would occupy my a part of space,so I want ask whether I can move it to other disk,and whether would have disadvantage.Thank you.
Yep - Go into settings in android studio and you can select where you want the sdk to reside. would it just move these folders too? Nah, you'd have to copy-paste them yourself.
You can delete these files without problems. Gradle will recreate it. Also these file are not committed and Version Control Systems. It means that when you checkout the project these files are not present on the project.
gradle folder location for Android studio, you must: Define the GRADLE_USER_HOME environment variable to point to C:\WorkFolder\ . gradle. You can read more in the Configure the IDE docs.
However, if you install/use that app again, the folders will recreate themselves. So the conclusion: Yes, you can delete the, if you do not use the apps associated with them.
Open Android Studio,
go to File > Settings... > Build, Execution, Deployment > Gradle
In Global Gradle settings
Change Service directory path to the desired folder.
Save the setting.
Now close Android Studio and move the .gradle from your C drive to the location you have chosen.
I have my .gradle on my second HDD (so that's how i did it)
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