# WeeChat Upgrade guidelines These upgrade guidelines only contain instructions for version upgrades which require manual actions.\ If a version is not listed here, that means no particular action is required for this version. When upgrading from version X to Y, please read and apply all instructions from version X+1 to version Y (both included). For a list of all changes in each version, please see [CHANGELOG.md](CHANGELOG.md). ## Version 4.10.0 ### Command on mouse click in fset buffer The command executed when clicking in the fset buffer has been updated to prevent errors on the core buffer when the click is done below the last option. To reset the key and use the new default command: ```text /reset weechat.key_mouse.@chat(fset.fset):button1 ``` ## Version 4.8.0 ### IRC temporary servers The IRC temporary server feature has been removed. When upgrading from an old version with `/upgrade`, any temporary server is converted to a standard server, and thus is saved in configuration file `irc.conf`. Servers can easily be removed with `/server del `. ### IRC SASL EXTERNAL When server option `sasl_mechanism` is set to `external`, WeeChat now sends the username defined in option `sasl_username` to the IRC server (see issue [#2270](https://github.com/weechat/weechat/issues/2270)). If you use the EXTERNAL mechanism and the username is set, you could either: - reset `sasl_username` to an empty string, if the username is **not** needed on this server: `/reset irc.server.xxx.sasl_username` - set `sasl_username` to your actual username, if the username **is** required on this server: `/set irc.server.xxx.sasl_username "user"` ### New time format in log files The time format used in log files now uses UTC and precision of microsecond by default: option `logger.file.time_format` has new default value: `%@%F %T.%fZ`. Only the default value for the option has changed, so when upgrading from an old version, you keep your old format, even if it was the default one used in previous versions. To use the new default value, you can reset the option: ```text /reset logger.file.time_format ``` ## Version 4.7.0 ### API functions utf8_next_char and utf8_char_size The function [utf8_next_char](https://weechat.org/doc/weechat/plugin/#_utf8_next_char) has been fixed and now returns NULL when an empty string is received (instead of the next char, which is after the end of string). The function [utf8_char_size](https://weechat.org/doc/weechat/plugin/#_utf8_char_size) has been fixed and now returns 0 when an empty string is received (instead of 1). ### API function util_version_number The function [util_version_number](https://weechat.org/doc/weechat/plugin/#_util_version_number) has been fixed and now returns an "unsigned long" instead of "int", so that any version up to "255.255.255.255" (0xFFFFFFFF) can be returned. ## Version 4.6.3 ### API function util_version_number An integer overflow has been fixed in the function [util_version_number](https://weechat.org/doc/weechat/plugin/#_util_version_number) which now returns a version up to "127.255.255.255" (0x7FFFFFFF). ## Version 4.6.0 ### Relay remote commands Commands on remote buffers can now be toggled: execution on remote WeeChat or locally, with a new default key: `Alt`+`Ctrl`+`l` (L). You can add this key with this command: ```text /key missing ``` ## Version 4.3.1 ### Detection of libgcrypt The detection of libgcrypt has been fixed to properly detect libgcrypt ≥ 1.11.\ As a consequence, the detection of an old version of libgcrypt is failing if the file `libgcrypt.pc` is not found.\ This affects old distributions like Debian Buster and Ubuntu Bionic. ## Version 4.3.0 ### Relay options The following relay options have been renamed: - relay.color.status_waiting_auth → relay.color.status_authenticating - relay.weechat.commands → relay.network.commands (new default value: `*,!quit`) ### Lag in buflist The lag is now stored in all IRC buffers: server (like it always has been), channels and private buffers. Consequently, if you use `${format_lag}` in buflist options, this lag will be displayed on server and all channels and private buffers. If you want to display the lag only on server buffer in buflist, you can use such format: ```text ${if:${type}==server?${format_lag}} ``` ### Color of IRC channel modes The option `irc.color.item_channel_modes` has been moved to core and renamed to `weechat.color.status_modes`. ### Signal "buffer_line_added" The signal "buffer_line_added" is now sent for every line added or modified on a buffer with free content. ## Version 4.2.2 ### Script keys Some arguments to the `/script` command were renamed in version 4.1.0, but the keys using these arguments were not changed at same time. They're now using the new arguments by default, but you must reset manually the keys with the following commands: ```text /reset weechat.key_mouse.@chat(script.scripts):button1 /reset weechat.key_mouse.@chat(script.scripts):button2 /reset weechat.key_mouse.@chat(script.scripts):wheeldown /reset weechat.key_mouse.@chat(script.scripts):wheelup ``` ## Version 4.2.0 ### Microseconds in buffer lines Microseconds have been added in buffer lines (for both date and printed date). Here are the changes that could affect plugins and scripts: - hook_print: the C callback receives a new argument "date_usec" (microseconds of date), after the argument "date" (scripting API is unchanged: the microseconds are not available) - trigger of types "print" and "timer": the format of variable `${tg_date}` is changed from `%Y-%m-%d %H:%M:%S` to `%FT%T.%f` (where `%f` is the number of microseconds on 6 digits) ### IRC anti-flood The anti-flood mechanism in IRC plugin has been improved and is now configured in milliseconds instead of seconds.\ It is done with a single option `irc.server_default.anti_flood` (and same option in servers), which replaces both options `anti_flood_prio_high` and `anti_flood_prio_low`. The default value is 2000 (2 seconds), and for example if you want to set a delay of 0.5 seconds between your messages sent: ```text /set irc.server_default.anti_flood 500 ``` When upgrading from an old WeeChat version, you'll see such messages, which are perfectly normal (they're displayed to warn you about unknown options, and then you have to set the new option if needed): ```text =!= | Warning: /home/user/.config/weechat/irc.conf, line 131: ignoring unknown option for section "server_default": anti_flood_prio_high = 2 =!= | Warning: /home/user/.config/weechat/irc.conf, line 132: ignoring unknown option for section "server_default": anti_flood_prio_low = 2 =!= | Warning: /home/user/.config/weechat/irc.conf, line 212: ignoring invalid value for option in section "server": libera.anti_flood_prio_high =!= | Warning: //home/user/.config/weechat/irc.conf, line 213: ignoring invalid value for option in section "server": libera.anti_flood_prio_low ``` ### Search in commands history Search in commands history has been added with new keys and a new key context called "histsearch". Some existing keys have been moved as well. New keys can be changed and added with the following commands after upgrade from an old WeeChat version: ```text /key missing /key unbind ctrl-s,ctrl-u /key bind meta-U /allbuf /buffer set unread /key bind ctrl-r /input search_history /key bindctxt search ctrl-r /input search_previous ``` ### RGB colors in IRC messages Support for RGB colors in IRC messages has been added and a new key `Ctrl`+`c`, `d` is available to insert this color code in command line. You can add this key with this command: ```text /key missing ``` ### Custom bar items Custom bar items must now have a different name than default bar items (for example the custom bar item name `time` is now forbidden).\ If you have such names in your config, WeeChat will now fail to load them (this should not happen anyway, since such bar items cannot be properly used or can cause a crash of WeeChat). ### Nick color infos The infos irc_nick_color and irc_nick_color_name are deprecated again, and the algorithm to compute IRC nick colors has been reverted to case-sensitive.\ The server name has been removed from arguments. ## Version 4.1.1 ### Custom bar items Custom bar items must now have a different name than default bar items (for example the custom bar item name `time` is now forbidden).\ If you have such names in your config, WeeChat will now fail to load them (this should not happen anyway, since such bar items cannot be properly used or can cause a crash of WeeChat). ## Version 4.1.0 ### New keys to move in cursor mode New keys have been added to move in cursor mode, and existing keys to move to another area have been changed: modifier is now `Alt`+`Shift` instead of `Alt`. You can change existing keys and add new ones with these commands: ```text /key bindctxt cursor meta-up /cursor move edge_top /key bindctxt cursor meta-down /cursor move edge_bottom /key bindctxt cursor meta-left /cursor move edge_left /key bindctxt cursor meta-right /cursor move edge_right /key bindctxt cursor meta-end /cursor move bottom_right /key bindctxt cursor meta-home /cursor move top_left /key bindctxt cursor meta-shift-up /cursor move area_up /key bindctxt cursor meta-shift-down /cursor move area_down /key bindctxt cursor meta-shift-left /cursor move area_left /key bindctxt cursor meta-shift-right /cursor move area_right ``` ### IRC CTCP replies IRC CTCP replies are now evaluated, with the same variables available, so now the syntax is for example `${version}` instead of `$version`.\ The existing options `irc.ctcp.*` are automatically converted on upgrade. In addition, for privacy reasons, these default CTCP replies have been removed: - FINGER - USERINFO If ever you want that WeeChat replies to these CTCP requests, you can add them back with the two following commands: ```text /set irc.ctcp.finger "WeeChat ${version}" /set irc.ctcp.userinfo "${username} (${realname})" ``` They will then be advertised in reply to "CTCP CLIENTINFO", which is now built dynamically with these options. ### Nick color infos Two infos to get nick colors have been added: nick_color_ignore_case and nick_color_name_ignore_case.\ They are similar to nick_color and nick_color_name, except they take as second argument a range of chars to apply on the nick: the nick is converted to lower case using this range of chars. The infos irc_nick_color and irc_nick_color_name, that were deprecated since version 1.5 are now used again, with a change in parameter: the server is now optional before the nick: "server,nick".\ The nick is first converted to lower case, following the value of CASEMAPPING on the server, then hashed to compute the color.\ That means the color for a nick is now case-insensitive (in the way IRC servers are case-insensitive, so with a limited range of chars only). If a script was using this info with a comma in nickname (which should not happen anyway), this is now interpreted as the server name, and the script must be modified.\ Anyway, it is recommended to always give the server name to respect the CASEMAPPING of the server and prevent any issue with a comma in the nickname. For example nick color of "alice" and "ALICE" is now always guaranteed to be the same: ```python # with server name (recommended) weechat.info_get("irc_nick_color", "libera,alice") == weechat.info_get("irc_nick_color", "libera,ALICE") weechat.info_get("irc_nick_color_name", "libera,alice") == weechat.info_get("irc_nick_color_name", "libera,ALICE") # without server name (allowed but not recommended, kept for compatibility) weechat.info_get("irc_nick_color", "alice") == weechat.info_get("irc_nick_color", "ALICE") weechat.info_get("irc_nick_color_name", "alice") == weechat.info_get("irc_nick_color_name", "ALICE") ``` ### Allowed values for options on fset buffer A new variable `allowed_values` has been added in fset options. The default value for the second format has changed.\ You can reset it with this command: ```text /reset fset.format.option2 ``` ### Mouse actions on fset buffer Mouse actions on fset buffer has been fixed when option `fset.look.format_number` is set to 2. The key for button 1 on fset buffer has been fixed.\ You can reset it with this command: ```text /reset weechat.key_mouse.@chat(fset.fset):button1 ``` ## Version 4.0.6 ### Custom bar items Custom bar items must now have a different name than default bar items (for example the custom bar item name `time` is now forbidden). If you have such names in your config, WeeChat will now fail to load them (this should not happen anyway, since such bar items cannot be properly used and can cause a crash of WeeChat). ## Version 4.0.1 ### Functions config_set_plugin and config_set_desc_plugin The functions [config_set_plugin](https://weechat.org/doc/weechat/plugin/#_config_set_plugin) and [config_set_desc_plugin](https://weechat.org/doc/weechat/plugin/#_config_set_desc_plugin) are not converting anymore the option name to lower case because since version 4.0.0, the name of options is case-sensitive. ### Grab raw key and command Key `Alt`+`K` (upper case) has been removed, as well as commands `/input grab_raw_key` and `/input grab_raw_key_command`. Now the key `Alt`+`k` displays the actual key name and command, possibly raw key. ## Version 4.0.0 This is a major version that includes breaking changes described below. ### Support of new IRC capabilities Support of new capabilities has been introduced in this version and are all enabled by default, if the server supports them: - batch - draft/multiline - echo-message When the capability "echo-message" is enabled, you may notice time before your own IRC messages are displayed in the buffer, this is normal : the capability forces the server to sent back messages, and WeeChat displays messages only when they are received from the server. If you want to disable this capability on all servers, you can do: ```text /set irc.server_default.capabilities "*,!echo-message" ``` If you are already connected to a server with echo-message enabled, just ask the server to disable the capability on-the-fly (no need to reconnect): ```text /cap req -echo-message ``` ### Configuration file version A version has been introduced in configuration file, and due to the many breaking changes (listed in the chapters below), the following files are automatically upgraded to a new version: - weechat.conf: new key names (see <>) - alias.conf: aliases converted to lower case (see <>) - irc.conf: options `ssl*` renamed to `tls*` (see <>) - relay.conf: options and protocol `ssl*` renamed to `tls*` (see <>) > [!WARNING] > Because of this new format, you must **NOT** load the new configuration files in any older WeeChat version < 4.0.0 once you have run any version ≥ 4.0.0 at least one time.\ For example the new key names make the input completely broken (you cannot enter most chars in input anymore and Enter key does not work). ### Key bindings improvements The format of key bindings has changed to be more user-friendly, and this is a breaking change: legacy keys are automatically converted, but some triggers, plugins or scripts might need manual changes. Overview of new features: - use of alias for keys (`meta-left` instead of `meta2-1;3D`) - use comma to separate keys in combos (`meta-w,meta-up` instead of `meta-wmeta-meta2-A`) - control keys are converted to lower keys (`ctrl-a` instead of `ctrl-A`) - keys are normal options, so they are shown and can be updated with `/set` and `/fset` commands - command `/key` without arguments opens the fset buffer with all keys See [Key bindings improvements specification](https://specs.weechat.org/specs/2023-002-key-bindings-improvements.html) for more information. #### New key format Aliases are now used for keys, like `f1`, `home`, `return`, etc.\ In addition, a comma is now required between different keys, for example `ctrl-cb` is not valid anymore and must be replaced by `ctrl-c,b`. The keys in weechat.conf are automatically converted from legacy format on first run or upgrade with a legacy configuration file. For keys bound in external plugins or scripts, WeeChat tries to convert them on-the-fly to stay compatible, but this cannot work in all cases (this is a breaking change). The following fixes are done on keys when they are defined: - transform upper case ctrl keys to lower case - replace space char by `space` - replace `meta2-` by `meta-[` (modifier `meta2-` doesn't exist anymore) - mouse modifiers are now in this order: `alt-` then `ctrl-`. A warning is displayed when a raw key or invalid key is added.\ For example `meta-[A` (which should be `up`) or `ctrl-ca` (missing comma, it should be `ctrl-c,a`). #### Grab raw key and command New key `Alt`+`K` (upper case) is added to grab raw key and its command. Most of times this command is not needed, and the existing key `Alt`+`k` (lower case) is preferred, as it returns the key using the new aliases. For example: - key `Alt`+`k` then up arrow displays: `up /input history_previous` - key `Alt`+`K` then up arrow displays: `meta-[A` Raw keys have higher priority than key with alias (they are looked first); they can still be used and bound, but this is not recommended.\ They should be used only in case of problem with the new aliases or with your terminal. #### Control keys as lower case Keys using the `Ctrl` key and a letter are now automatically converted to lower case.\ That means for example keys `ctrl-q` and `ctrl-Q` are the same and saved as `ctrl-q` (lower case). Example of key being automatically converted to lower case: ```text /key bind ctrl-Q /print test ``` Output is now: ```text New key binding (context "default"): ctrl-q => /print test ``` With older releases, upper case was mandatory and lower case letter for control keys were not working at all. ### Case-sensitive identifiers Many identifiers are made case-sensitive, including among others: - configuration files, sections, options - commands, aliases - completion (except nick completion) - bars, bar items - colors - filters - IRC servers - scripts - triggers. See [Case-sensitive identifiers specification](https://specs.weechat.org/specs/2023-001-case-sensitive-identifiers.html) for more information. Accordingly, default aliases are now in lower case.\ All aliases (default ones and those added manually) are automatically converted to lower case with a message like this one: ```text Alias converted to lower case: "CLOSE" => "close" ``` ### TLS options and connections Option `weechat.color.status_name_insecure` has been added, the buffer name is now displayed with color `lightmagenta` by default if the connection with the server is **NOT** made with TLS. Options, commands and documentation have been updated to "TLS" instead of "SSL": - core option: - weechat.color.status_name_ssl → weechat.color.status_name_tls - IRC server default options: - irc.server_default.ssl → irc.server_default.tls - irc.server_default.ssl_cert → irc.server_default.tls_cert - irc.server_default.ssl_dhkey_size → irc.server_default.tls_dhkey_size - irc.server_default.ssl_fingerprint → irc.server_default.tls_fingerprint - irc.server_default.ssl_password → irc.server_default.tls_password - irc.server_default.ssl_priorities → irc.server_default.tls_priorities - irc.server_default.ssl_verify → irc.server_default.tls_verify - IRC options for a specific server: - irc.server.xxx.ssl → irc.server.xxx.tls - irc.server.xxx.ssl_cert → irc.server.xxx.tls_cert - irc.server.xxx.ssl_dhkey_size → irc.server.xxx.tls_dhkey_size - irc.server.xxx.ssl_fingerprint → irc.server.xxx.tls_fingerprint - irc.server.xxx.ssl_password → irc.server.xxx.tls_password - irc.server.xxx.ssl_priorities → irc.server.xxx.tls_priorities - irc.server.xxx.ssl_verify → irc.server.xxx.tls_verify - Relay options: - relay.network.ssl_cert_key → relay.network.tls_cert_key - relay.network.ssl_priorities → relay.network.tls_priorities - Relay: - protocol `ssl` → `tls` - Relay command: - `/relay sslcertkey` → `/relay tlscertkey` Default value of option `irc.server_default.tls` is now `on`.\ Connection to IRC servers is done with TLS and port 6697 by default. For example to create libera.chat server, using TLS (if option `irc.server_default.tls` is `on`) and default port 6697: ```text /server add libera irc.libera.chat irc: server added: libera -> irc.libera.chat/6697 (TLS: enabled) ``` To force non-TLS connection (with default port 6667): ```text /server add libera irc.libera.chat -notls irc: server added: libera -> irc.libera.chat/6667 (TLS: disabled) ``` ### Insert of multiple pasted lines in input By default multiple pasted lines are now inserted in input and not sent immediately. To enable this feature, the default value of option `weechat.look.paste_max_lines` has been changed to `100` (it was `1`).\ If needed, you can reset the option to the new default value after upgrade: ```text /reset weechat.look.paste_max_lines ``` The option `weechat.look.paste_auto_add_newline` has been removed. ### Default triggers The default triggers "cmd_pass", "cmd_pass_register" and "server_pass" have been updated to be compatible with multiline input. You can restore these default triggers with the following command: ```text /trigger restore cmd_pass cmd_pass_register server_pass ``` ### Build #### Autotools The autotools support for build of WeeChat has been removed.\ WeeChat must now be built with CMake. #### Documentation The auto-generated files for documentation are now built with `weechat-headless`, after compilation of WeeChat and the plugins (the files are not in repository anymore).\ This implies all plugins must be compiled and loaded in order to have complete docs (User's guide and Plugin API reference). If ever you want to disable some plugins and force the build of incomplete docs, a new option has been added: `ENABLE_DOC_INCOMPLETE` (`OFF` by default). For example if you disable PHP plugin but still want docs where PHP options, commands, etc. are missing: ```bash cmake .. -DENABLE_PHP=OFF -DENABLE_DOC=ON -DENABLE_DOC_INCOMPLETE=ON ``` ### Packaging #### Tarballs The command `make dist` now builds only `.gz` and `.xz` compressed tarballs.\ Formats `.bz2` and `.zst` are not built anymore. #### RPM packaging The file `weechat.spec` used for RPM packaging has been removed.\ openSUSE has its own here: https://build.opensuse.org/package/view_file/server:irc/weechat/weechat.spec?expand=1 #### cpack The configuration for cpack has been removed.\ It was used to build binary package of WeeChat, which has never been released in this format. ### Function bar_new When the bar name already exists, the API function [bar_new](https://weechat.org/doc/weechat/plugin/#_bar_new) returns the pointer to the bar (instead of NULL) and sets the default value for all options with the values received.\ If you don't want to set default values in an existing bar, it is recommended to first check if the bar exists with the API function [bar_search](https://weechat.org/doc/weechat/plugin/#_bar_search). ## Version 3.8 ### Move of options out of command /input Some options of `/input` command have been moved to other commands (they can still be used with `/input` but marked as deprecated and completion has been removed): Old command | New command | Default key --------------------------------------- | ----------------------------- | ---------------------- `/input jump_smart` | `/buffer jump smart` | `Alt`+`a` `/input jump_previously_visited_buffer` | `/buffer jump prev_visited` | `Alt`+`<` `/input jump_next_visited_buffer` | `/buffer jump next_visited` | `Alt`+`>` `/input jump_last_buffer_displayed` | `/buffer jump last_displayed` | `Alt`+`/` `/input hotlist_clear` | `/hotlist clear` | `Alt`+`h`, `Alt`+`c` `/input hotlist_remove_buffer` | `/hotlist remove` | `Alt`+`h`, `Alt`+`m` `/input hotlist_restore_buffer` | `/hotlist restore` | `Alt`+`h`, `Alt`+`r` `/input hotlist_restore_all` | `/hotlist restore -all` | `Alt`+`h`, `Alt`+`Shift`+`R` `/input set_unread` | `/allbuf /buffer set unread` | `Ctrl`+`s`, `Ctrl`+`u` `/input set_unread_current_buffer` | `/buffer set unread` | (none) `/input switch_active_buffer` | `/buffer switch` | `Ctrl`+`x` `/input switch_active_buffer_previous` | `/buffer switch -previous` | (none) `/input zoom_merged_buffer` | `/buffer zoom` | `Alt`+`x` The following default keys can be reset to use the new command: ```text /key reset meta-a /key reset meta-< /key reset meta-> /key reset meta-/ /key reset meta-hmeta-c /key reset meta-hmeta-m /key reset meta-hmeta-r /key reset meta-hmeta-R /key reset ctrl-Sctrl-U /key reset ctrl-X /key reset meta-x ``` ### Return code of string comparison functions The following functions now return arithmetic result of subtracting the last compared UTF-8 char in string2 from the last compared UTF-8 char in string1: - string_charcmp - string_charcasecmp - string_charcasecmp_range - string_strcasecmp - string_strcasecmp_range - string_strncasecmp - string_strncasecmp_range - string_strcmp_ignore_chars In addition, the case conversion has been extended, now in addition to range A-Z, all chars that have a lower case version are handled.\ That means for example the case-insensitive comparison of "é" and "É" is 0 (chars are considered equal). Example with WeeChat 3.8: ```c int diff = string_strcasecmp ("aaa", "CCC"); /* == -2 */ ``` With older releases: ```c int diff = string_strcasecmp ("aaa", "CCC"); /* == -1 */ ``` ### API functions string_tolower and string_toupper The functions [string_tolower](https://weechat.org/doc/weechat/plugin/#_string_tolower) and [string_toupper](https://weechat.org/doc/weechat/plugin/#_string_toupper) now return newly allocated string instead of doing the change in place.\ The returned string must then be freed after use. ### Trigger regex command The trigger regex now starts with a command, which is "s" (regex replace, default) or "y" (translate chars). For compatibility, any regex starting with a delimiter different from a letter will still work. If you defined some triggers with a regex starting with a letter (used as delimiter), then you must change them **before** upgrading WeeChat, otherwise they'll be lost after upgrade (with an error when WeeChat tries to load them from configuration file). For example this regex is now invalid: ```text XabcXdefX ``` And must be replaced by: ```text sXabcXdefX ``` For more information on the regex format, see the trigger chapter in the _WeeChat User's guide_. ### Remove Python 2 support The CMake option `ENABLE_PYTHON2` and autotools option `--enable-python2` have been removed, and WeeChat cannot be compiled with Python 2.x anymore. ### Callbacks of function config_new_option The two callbacks "callback_change" and "callback_delete" in scripting API function config_new_option have been changed: an integer return value was expected by error, now any return value is ignored (like it has always been in the C API). ## Version 3.7 ### Argument "object_id" in callback of upgrade_new In all script languages (except PHP), the argument "object_id" sent to the callback of "upgrade_new" is now an integer (it was a string in older releases). To be compatible with all versions, it is recommended to convert the argument to integer before testing it, for example in Python: ```python if int(object_id) == 1: # ... ``` ### Argument "remaining_calls" in callback of hook_timer In all script languages (except PHP), the argument "remaining_calls" sent to the callback of "hook_timer" is now an integer (it was a string in older releases). To be compatible with all versions, it is recommended to convert the argument to integer before testing it, for example in Python: ```python if int(remaining_calls) > 0: # ... ``` ### Delete previous word until whitespace A new parameter `delete_previous_word_whitespace` has been added in `/input` command to delete previous word until backspace.\ This is now bound by default to the key `Ctrl`+`w` (see issue [#559](https://github.com/weechat/weechat/issues/559)). A new key kbd:[Alt+Backspace] has been added to delete word, like `Ctrl`+`w` did in previous releases. You can get the new behavior for `Ctrl`+`w` with this command: ```text /key bind ctrl-W /input delete_previous_word_whitespace ``` And add the new key `Alt`+`Backspace` with this command: ```text /key missing ``` ### Function string_rebuild_split_string The API function string_build_with_split_string has been renamed to [string_rebuild_split_string](https://weechat.org/doc/weechat/plugin/#_string_rebuild_split_string) and two new arguments have been added: _index_start_ and _index_end_. To stay compatible, the existing calls to the function must be done with the new function name and these values: - _index_start_: `0` - _index_end_: `-1` ## Version 3.6 ### Hook print on empty messages The "hook_print" callback is now called even when an empty message is displayed (with or without prefix). This was a bug, but is mentioned here just in case some scripts callbacks would be surprised to be called with such empty messages. ### Default trigger "beep" The command of "beep" trigger is now executed only if the buffer notify is NOT set to `none` (in addition to existing conditions). You can restore the default trigger "beep" with the following command: ```text /trigger restore beep ``` ## Version 3.5 ### Compression "zstandard" in relay Relay of type "weechat" now offers a compression with [Zstandard](https://facebook.github.io/zstd/), which allows better compression and is much faster than zlib for both compression and decompression. The new compression type is `zstd`, and the default compression is now `off` instead of `zlib`: the compression must now be explicitly given in the [handshake](https://weechat.org/doc/weechat/relay/#command_handshake) command. The option `compression` in [init](https://weechat.org/doc/weechat/relay/#command_handshake) command has been removed, it is now ignored and must be given in the [handshake](https://weechat.org/doc/weechat/relay/#command_handshake) command (it was deprecated since WeeChat 2.9). The option relay.network.compression_level has been renamed to relay.network.compression and is now a percentage between `0` and `100`: - `0`: disable compression - `1`: low compression (fast) - `100`: best compression (slow) ## Version 3.4 ### Default triggers The existing triggers "cmd_pass" and "cmd_pass_register" have been updated to hide key and password in command `/msg nickserv setpass ` and support the option `-server `. You can restore the default triggers with the following command: ```text /trigger restore cmd_pass cmd_pass_register ``` ### New parameters in function hdata_search New parameters have been added in function [hdata_search](https://weechat.org/doc/weechat/plugin/#_hdata_search), used for the evaluation of expression. New parameters are the same as function [string_eval_expression](https://weechat.org/doc/weechat/plugin/#_string_eval_expression): - pointers: hashtable with pointers (pointers) - extra_vars: hashtable with extra variables (strings) - options: hashtable with options (strings). The following scripts are updated consequently to be compatible with all WeeChat versions: - [autoauth.py](https://weechat.org/scripts/source/autoauth.py/) 1.3 - [buffer_open.py](https://weechat.org/scripts/source/buffer_open.py/) 0.3 - [collapse_channel.py](https://weechat.org/scripts/source/collapse_channel.py/) 0.9 - [grep_filter.py](https://weechat.org/scripts/source/grep_filter.py/) 0.11 - [samechannel.rb](https://weechat.org/scripts/source/samechannel.rb/) 0.2 - [soju.py](https://weechat.org/scripts/source/soju.py/) 0.1.4 - [stalker.pl](https://weechat.org/scripts/source/stalker.pl/) 1.6.3 ### Static array support in hdata Support of static array in hdata has been added. For pointers to arrays, a prefix `*,` must be added in parameter `array_size` of API function [hdata_new_var](https://weechat.org/doc/weechat/plugin/#_hdata_new_var). ## Version 3.3 ### New keys for hotlist New keys have been added to manipulate the hotlist: - `Alt`+`h`, `Alt`+`c`: clear the whole hotlist (former key: `Alt`+`h`) - `Alt`+`h`, `Alt`+`m`: mark the current buffer as read by removing it from the hotlist - `Alt`+`h`, `Alt`+`r`: restore latest hotlist removed in the current buffer - `Alt`+`h`, `Alt`+`Shift`+`R`: restore latest hotlist removed in all buffers You can add them with the following command: ```text /key missing ``` Since the key `Alt`+`h` has been moved to `Alt`+`h`, `Alt`+`c`, you must manually remove the old key: ```text /key unbind meta-h ``` ### Bar item "typing" A bar item called "typing" has been added to status bar by default. It is used to display users that are currently typing a message on the current IRC channel or private buffer. If you want to display typing notifications in the status bar, add `,[typing]` in your option weechat.bar.status.items. ### Ordered hashtables Hashtables entries are now ordered by creation date, the following functions are now returning entries sorted by insertion order: - hashtable_map - hashtable_map_string - hashtable_get_string (all properties except "keys_sorted" and "keys_values_sorted") - hashtable_add_to_infolist ### IRC default capabilities All supported capabilities are now enabled by default if the server support them: - account-notify - away-notify - cap-notify - chghost - extended-join - invite-notify - message-tags - multi-prefix - server-time - setname - userhost-in-names Two new options have been added and enabled by default to customize the behavior of capabilities "account-notify" and "extended-join": - irc.look.display_account_message: display ACCOUNT messages received - irc.look.display_extended_join: display extended join info in the JOIN messages: account name and real name The default value of option irc.server_default.capabilities is now `*` which means that all capabilities supported by both WeeChat and the server are enabled by default. After upgrade, to enable all capabilities and remove custom capabilities you have set, you can do: ```text /set irc.server_default.capabilities "*" /unset irc.server.example.capabilities ``` You can also explicitly disable some capabilities with this syntax (see `/help irc.server_default.capabilities`): ```text /set irc.server_default.capabilities "*,!away-notify,!extended-join" ``` ### IRC SASL DH-BLOWFISH and DH-AES mechanisms removed The SASL mechanisms DH-BLOWFISH and DH-AES have been removed, because they are insecure and already removed from most IRC servers.\ If you were using one of these mechanisms, it is highly recommended to switch to any other supported SASL mechanism. For example: ```text /set irc.server.example.sasl_mechanism scram-sha-256 ``` ## Version 3.2 ### XDG directories Support of XDG directories has been added. For compatibility, if the XDG directories are not found but `~/.weechat` exists, this single directory is used for all files. If you want to switch to XDG directories, you must create and move manually all files in the appropriate directories.\ See [WeeChat XDG specification](https://specs.weechat.org/specs/001285-follow-xdg-base-dir-spec.html#weechat-home) for more information. Some options have new default value: `%h` is replaced by `${weechat_xxx_dir}`.\ If you didn't change the value, it is recommended to set the new default value, by doing `/unset