So I regularly have to clean out my `$GRADLE_USER_...
# community-support
t
So I regularly have to clean out my
$GRADLE_USER_HOME/.gradle/caches/<version>/transforms
directory which is gathering multiple gigabytes worth of duplicated transformed libraries that get generated through my multi component build. Now I know Gradle is first about correctness and speed and secondly only cares about optimizing cache sizes and the like, but I really, really would love to have some option in Gradle to clear outdated / unused caches. Not only transforms, but in general also cache folders from older Gradle versions, old cached distributions and the like. I know I could write a script and do it myself in one go, but then Gradle daemons need to be stopped properly, no new Gradle daemons must be started (otherwise Gradle stumbles upon corrupted caches) and in general I think it's Gradle's task to deal with its caches, not only creating them, but also keeping them under control. Is anything planned in this direction / is there eventually a ticket that I could subscribe to that would deal with that?
plus1 3
a
There is a configuration for cache cleanupdocs.gradle.org/current/userguide/directory_layout.html#… and there are some defaults set. If it doesn't work ok then it's worth reporting. Note that cleanup is time retention based, and not size based.
t
Thanks, I'll look into this!