Override defaults in cache.php

Is there a way to override this in cache.php:

protected static $standard_remove = [

protected static $all_remove = [

protected static $assets_remove = [

protected static $images_remove = [

protected static $cache_remove = [

In a plugin? I want to remove all instances of ‘cache://images’,

It is an interesting thought, I would presume one of the event hooks could do it, though I am not familiar with the process. I would be interested in your results though, disabling the caching of images could be useful where this is done manually or outside of Grav.

I’m not trying to prevent the caching of images, but to prevent the clearing of cached images on every cache-clear. My image cache is +1GB so I don’t want to recreate all images on every cache-clear. Anyway, I extended the Cache class in a plugin, and set the variables in my own class using parent::$standard_remove = $caches;
and it works. The only thing I’m still wondering is whether cli cache-clear commands reacts in the same manner to the events, as would a normal page request.

Currently there is no way to override these. However, improvements an be added to the core version by providing a Pull Request if the are generic enough to be of use for everyone.