Skip to content

thumbnailers: Allow a local cache directory with bubblewrap

This merge requests adds two keys to .thumbnailer files for use with bubblewrap:

  • AllowPathsRO: Read-only paths
  • AllowPathsRW: Read-write paths

The main use case is for my ROM Properties extension (https://github.com/GerbilSoft/rom-properties), which has a function that downloads images from online databases to use as thumbnails for certain types of disc and/or ROM images. These images are downloaded to ~/.cache/rom-properties, which is currently not accessible by the thumbnailer process due to bubblewrap.

To support this use case, the path parser also supports variable expansion. Currently, only one variable, ${XDG_CACHE_HOME}, is supported. This variable is handled by using g_get_user_cache_dir(). ~ for the home directory is also supported, which is needed for the use case in #131 (adding ~/.local/bin/ to the path).

This fixes #162 (closed), which was originally posted as a feature request. This might also fix #131, since the .thumbnailer file can specify a custom directory.

Edited by Michael Catanzaro

Merge request reports