core: add a warning in header of configuration files to not edit by hand (closes #851)
This commit is contained in:
parent
2165610401
commit
fe95a1c8a8
@ -24,6 +24,7 @@ New features::
|
||||
|
||||
Improvements::
|
||||
|
||||
* core: add a warning in header of configuration files to not edit by hand (issue #851)
|
||||
* irc: change default value of option irc.network.lag_reconnect to 300 (issue #818)
|
||||
* trigger: do not hide email in command "/msg nickserv register password email" (issue #849)
|
||||
|
||||
|
@ -2459,13 +2459,23 @@ config_file_write_internal (struct t_config_file *config_file,
|
||||
}
|
||||
|
||||
/* write header with name of config file and WeeChat version */
|
||||
if (!string_fprintf (config_file->file, "#\n"))
|
||||
goto error;
|
||||
if (!string_fprintf (config_file->file,
|
||||
"# %s -- %s\n#\n",
|
||||
version_get_name (),
|
||||
config_file->filename))
|
||||
if (!string_fprintf (
|
||||
config_file->file,
|
||||
"#\n"
|
||||
"# %s -- %s\n"
|
||||
"#\n"
|
||||
"# WARNING: It is NOT recommended to edit this file by hand,\n"
|
||||
"# especially if WeeChat is running.\n"
|
||||
"#\n"
|
||||
"# Use /set or similar command to change settings in WeeChat.\n"
|
||||
"#\n"
|
||||
"# For more info, see: https://weechat.org/doc/quickstart\n"
|
||||
"#\n",
|
||||
version_get_name (),
|
||||
config_file->filename))
|
||||
{
|
||||
goto error;
|
||||
}
|
||||
|
||||
/* write all sections */
|
||||
for (ptr_section = config_file->sections; ptr_section;
|
||||
|
Loading…
x
Reference in New Issue
Block a user