wireplumber/modules/module-lua-scripting
Peter Hutterer d38c3fb4cc lib: add functions to search in configuration/data directories
The previous approach to loading config files was to ask WP for the
directory and then search those for the config files. This patch changes the
approach - a caller now asks WP to search for a specific config file or
iterate over a config file directory.

This allows us to implement a directory lookup order, i.e.
"wireplumber.conf" may be in XDG_CONFIG_DIR, /etc/,
/usr/share and the first one found is used.

For configuration directories, the new method iterates over all matching
entries (files + directories) and invokes a callback for each entry.

This enables distributions to ship default files in /usr/share/wireplumber
but have admins and users override them on a local basis. For lua scripts in
particular, overriding a distribution-provided file with an empty file
effectively disables it, adding a file adds it in the right sort order.
2021-07-15 15:17:01 +00:00
..
api.c lua: add Port.get_direction() + documentation for it 2021-06-30 19:51:21 +03:00
api.lua lua: add not-equals to the possible constraint verbs 2021-07-02 20:24:25 +03:00
config.c lib: add functions to search in configuration/data directories 2021-07-15 15:17:01 +00:00
gresource.xml modules: implement module-lua-scripting 2020-12-20 18:10:22 +02:00
pod.c m-lua-scripting: unref value pod after adding it to control 2021-06-30 14:06:48 -04:00
require.c lua: add a Core.require_api() utility function 2021-04-09 15:52:17 +03:00