Allow for a configurable cache location

This commit is contained in:
Grant Sanderson
2024-12-04 20:50:42 -06:00
parent 0c385e820f
commit 89ddfadf6b
4 changed files with 16 additions and 8 deletions

View File

@ -1,5 +1,6 @@
import os
import tempfile
import appdirs
from manimlib.config import get_custom_config
from manimlib.config import get_manim_dir
@ -17,6 +18,9 @@ def get_customization():
if not directories["temporary_storage"]:
directories["temporary_storage"] = tempfile.gettempdir()
if not directories["cache"]:
directories["cache"] = appdirs.user_cache_dir("manim")
# Assumes all shaders are written into manimlib/shaders
directories["shaders"] = os.path.join(
get_manim_dir(), "manimlib", "shaders"