-
I can understand the pain. Will support multiple cache paths in future versions.
-
Any chance to also consider exclude rules? Otherwise one has to regularly check if something in the build tool might have changed and additional folders need to be cached.
Would be way simpler to say "Please cache
.gradlebut excludegradle.propertiesandinit.gradle". -
Previous Value Current Value Build cache excludes / multiple folders in same cache?
Able to specify multiple paths in same cache step
-
OneDev
changed state to 'Closed' 2 years ago
Previous Value Current Value Open
Closed
-
State changed as code fixing the issue is committed (71c8f014)
-
OneDev
changed state to 'Released' 2 years ago
Previous Value Current Value Closed
Released
-
State changed as build #4819 is successful
| Type |
Improvement
|
| Priority |
Normal
|
| Assignee | |
| Labels |
No labels
|
Issue Votes (0)
I am mainly using Gradle to build projects and I am also using a custom docker image to run Java based jobs. The docker image pre-configures some Gradle/Maven settings for the root user by placing
/root/.gradle/gradle.properties,/root/.gradle/init.gradle,/root/.m2/settings.xmland/root/.mavenrcinside the image.Now if I want to cache Maven data it is relatively simple by caching
/root/.m2/repository. However for Gradle the.gradlefolder contains many directories and I would need to define a cache per directory. Ideally I want to cache.gradleand exclude some files like the ones mentioned above. However if OneDev would allow excludes it must also make sure that unpacking.gradledoes not replace the existing.gradlefolder and we do not loose files already present in that folder. Otherwise the running job container would not have the pre-configured Gradle settings anymore..gradlecontents:Instead of excludes OneDev could alternatively allow multiple cache paths in a single cache. Currently it only allows a single cache path.