Make spotless tasks all cacheable with the Gradle Build Cache
See original GitHub issueThis should be as simple as adding the @CachableTask
annotation to all of the relevant tasks.
Issue Analytics
- State:
- Created 5 years ago
- Comments:15 (15 by maintainers)
Top Results From Across the Web
Build Cache - Gradle User Manual
The Gradle build cache is a cache mechanism that aims to save time by reusing outputs produced by other builds. The build cache...
Read more >Gradle Build Cache Basics - Baeldung
The Gradle build cache is semi-permanent storage that saves the build tasks' outputs. It enables the reuse of already generated artifacts ...
Read more >Caching for faster builds | Gradle Enterprise Docs
At this point, the build is fully configured and ready to run. We will run this build with a clean , which will...
Read more >Turbocharging your Android Gradle builds using the build cache
Put org.gradle.caching=true in your gradle.properties file. Gradle will attempt to reuse outputs from previous builds for all builds.
Read more >Gradle Build Cache after gradle clean - Stack Overflow
The build cache does not store the task outputs in the project workspace, but in a local or remote build cache. The local...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
An issue that we’re going to have (just popped up in #559) is that most of our
FormatterStep
cache keys are machine-dependent at the moment. The task reorganization that @bigdaz has proposed is a definite improvement, and will make the local buildcache useful to users. But in order for Spotless to be path-independent (necessary for shared buildcache to be useful), we need to makeFileSignature
path and machine independent. I think we should discuss and implement this separately, the issue lives at #566.I did a quick investigation, and it looks like we can probably support this usecase by bumping our minimum-required gradle to
3.0
, and we can certainly support it if we bump to3.5
. We have to go all the way to4.9
to get completely native config-avoidance APIs, which is the other sticking point we’ve had.No need for a screenshot, a gradle engineer with a real customer usecase is proof-enough for me that there’s value in bumping the minimum. I’m definitely on-board with bumping to
3.0
(3.5
if necessary), and if this heavy-duty usecase can also show that we get measurable benefit from4.9
then I’m okay with that too. Implementing this is not high on my apocalypse-todo-list, but releasing good PRs quickly is always high on my todo list, even in an apocalypse.