Allow custom cache directory
Currently the cache appears to be global, but it would be useful to set a per-repository cache directory (ideally in .gersemirc) to avoid mixing caches between projects.
The .gersemirc entry, if a relative path, should be relative to the position of .gersemirc.
I have customizing cache directory actually ready in my local copy but I haven't published it yet due to various reasons. However it won't be available through .gersemirc because that's strictly used for outcome configuration and cache isn't part of that. Is there a problem with common cache?
Is there a problem with common cache?
The directory chosen by appdirs.user_cache_dir() (which appears to be being used to specify the cache location) may not be writeable (for example on clusters).
So it would be nice to be able to set the cache dir through configuration option directly. I mention relative paths here because the repository directory will almost certainly always be writeable so it would make sense to put the cache there.
Ok, totally different use case than mine but equally valid. I'll try to release customizing cache directory soon-ish.
Although I'm going to change appdirs dependency to platformdirs I've found out that technically you already could affect cache directory, at least on Linux, with XDG_CACHE_HOME.
You can change cache directory directly through --cache-dir argument or indirectly with environmental variables (like XDG_CACHE_HOME on Linux) in release 0.24.0. About environmental variables for your OS please consult with documentation of platformdirs.