How to delete Gradle cache files

If, like me, you are having troubles compiling projects (also Android Studio ones) after having upgraded Gradle you can try to delete cache files. I’m assuming you are working on a Linux box and that your Android projects are saved inside  ~/AndroidStudioProjects/ How to delete general caches:

How to delete Android Studio caches:

I […]