[
https://issues.apache.org/jira/browse/MBUILDCACHE-93?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17840988#comment-17840988
]
ASF GitHub Bot commented on MBUILDCACHE-93:
-------------------------------------------
kbuntrock commented on code in PR #148:
URL:
https://github.com/apache/maven-build-cache-extension/pull/148#discussion_r1580180732
##########
src/site/markdown/parameters.md:
##########
@@ -36,6 +36,7 @@ This document contains various configuration parameters
supported by the cache e
| `-Dmaven.build.cache.restoreGeneratedSources=(true/false)` | Do not restore
generated sources and directly attached files
| Performance optimization
|
| `-Dmaven.build.cache.alwaysRunPlugins=<list of plugins>` | Comma separated
list of plugins to always run regardless of cache state. An example:
`maven-deploy-plugin:*,maven-install-plugin:install` | Remote cache
setup/tuning/troubleshooting |
| `-Dmaven.build.cache.skipCache=(true/false)` | Skip looking up
artifacts in caches. Does not affect writing artifacts to caches, disables only
reading when set to `true` | May be used to trigger a forced
rebuild when matching artifacts do exist in caches |
+| `-Dmaven.build.cache.saveDisabled=(true/false)` | Skip writing
build result in caches. Does not affect reading from the cache. |
Configuring MR builds to benefits from the cache, but restricting writes to the
`master` branch |
Review Comment:
Works for me (it's even the title of my branch 😋).
I've updated my commit.
> Command line configuration to disable saving in cache
> -----------------------------------------------------
>
> Key: MBUILDCACHE-93
> URL: https://issues.apache.org/jira/browse/MBUILDCACHE-93
> Project: Maven Build Cache Extension
> Issue Type: New Feature
> Reporter: Kevin Buntrock
> Priority: Minor
> Labels: pull-request-available
>
> Command line configuration to disable saving in cache.
> We have already a configuration to :Â
> - Disable totally any cache interaction
> - Disable restoring from the cacheÂ
> - Disable saving on the remote cache
> But there is no configuration to disable "classic" saving to the cache.
> Use case can be :
> Having limited space on machine and therefore a limited number of saved build
> allowed.
> -> Restricting cache save to the "master" branch / configuring PR branch
> build to benefits from the cache, but disallowing any save from them
> It's personally a functionality I use since November and the cache hit rate
> on my project with this technic is pretty nice.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)