mirror of
https://github.com/aljazceru/lightning.git
synced 2026-01-26 09:14:20 +01:00
plugins: document and extend the ~/.lightning/plugins/ dir.
Load any plugins directly as well as subdirs. Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
This commit is contained in:
committed by
Christian Decker
parent
4f937ea1f0
commit
310d806dd3
@@ -909,6 +909,9 @@ void plugins_add_default_dir(struct plugins *plugins, const char *default_dir)
|
||||
DIR *d = opendir(default_dir);
|
||||
if (d) {
|
||||
struct dirent *di;
|
||||
|
||||
/* Add this directory itself, and recurse down once. */
|
||||
add_plugin_dir(plugins, default_dir, true);
|
||||
while ((di = readdir(d)) != NULL) {
|
||||
if (streq(di->d_name, ".") || streq(di->d_name, ".."))
|
||||
continue;
|
||||
|
||||
Reference in New Issue
Block a user