summaryrefslogtreecommitdiff
path: root/doc/en/weechat_plugin_api.en.adoc
diff options
context:
space:
mode:
Diffstat (limited to 'doc/en/weechat_plugin_api.en.adoc')
-rw-r--r--doc/en/weechat_plugin_api.en.adoc12
1 files changed, 10 insertions, 2 deletions
diff --git a/doc/en/weechat_plugin_api.en.adoc b/doc/en/weechat_plugin_api.en.adoc
index 95d00a573..d8c23f836 100644
--- a/doc/en/weechat_plugin_api.en.adoc
+++ b/doc/en/weechat_plugin_api.en.adoc
@@ -6263,7 +6263,7 @@ Functions for configuration files.
==== config_new
-_Updated in 1.5._
+_Updated in 1.5, 3.9._
Create a new configuration file.
@@ -6281,7 +6281,11 @@ struct t_config_file *weechat_config_new (const char *name,
Arguments:
-* _name_: name of configuration file (without path or extension)
+* _name_: name of configuration file (without path or extension); a priority
+ is allowed before the name, with format `nnn|name` where `nnn` is non-negative
+ integer with priority; default priority is 1000; files are sorted by priority
+ from higher to lower when running command `/reload`
+ (see priority of configuration files below)
* _callback_reload_: function called when configuration file is reloaded with
`/reload` (optional, can be NULL, see below), arguments and return value:
** _const void *pointer_: pointer
@@ -6317,6 +6321,10 @@ You should call this function only after adding some sections (with
<<_config_new_section,config_new_section>>) and options (with
<<_config_new_option,config_new_option>>).
+Priority of default configuration files:
+
+include::includes/autogen_api_config_priority.en.adoc[tag=config_priority]
+
C example:
[source,c]