Comparison

prosodyctl @ 4167:9c60cc8dc142

prosody, prosodyctl: Use plugin_paths in addition to, not instead of, the default plugin path
author Matthew Wild <mwild1@gmail.com>
date Thu, 24 Feb 2011 01:35:33 +0000
parent 4158:14581c3f33bd
child 4324:5e7cba840409
comparison
equal deleted inserted replaced
4166:3ac90743039b 4167:9c60cc8dc142
110 config.set("*", "core", "log", { { levels = { min="info" }, to = "console" } }); 110 config.set("*", "core", "log", { { levels = { min="info" }, to = "console" } });
111 111
112 local data_path = config.get("*", "core", "data_path") or CFG_DATADIR or "data"; 112 local data_path = config.get("*", "core", "data_path") or CFG_DATADIR or "data";
113 local custom_plugin_paths = config.get("*", "core", "plugin_paths"); 113 local custom_plugin_paths = config.get("*", "core", "plugin_paths");
114 if custom_plugin_paths then 114 if custom_plugin_paths then
115 CFG_PLUGINDIR = table.concat(custom_plugin_paths, package.config:sub(3,3)); -- path1;path2;path3 115 local path_sep = package.config:sub(3,3);
116 -- path1;path2;path3;defaultpath...
117 CFG_PLUGINDIR = table.concat(custom_plugin_paths, path_sep)..path_sep..(CFG_PLUGINDIR or "plugins");
116 end 118 end
117 prosody.paths = { source = CFG_SOURCEDIR, config = CFG_CONFIGDIR, 119 prosody.paths = { source = CFG_SOURCEDIR, config = CFG_CONFIGDIR,
118 plugins = CFG_PLUGINDIR, data = data_path }; 120 plugins = CFG_PLUGINDIR or "plugins", data = data_path };
119 121
120 require "core.loggingmanager" 122 require "core.loggingmanager"
121 123
122 dependencies.log_warnings(); 124 dependencies.log_warnings();
123 125