1
0
mirror of https://github.com/weechat/weechat.git synced 2026-06-13 14:44:46 +02:00

Compare commits

...

344 Commits

Author SHA1 Message Date
Sébastien Helleu 7d5dc53cd9 Version 2.8 2020-03-29 09:39:36 +02:00
Sébastien Helleu e086bc44f5 core: add version 2.7.1 in weechat.spec 2020-03-29 09:30:35 +02:00
Sébastien Helleu 8738196b68 tests: add tests on remaining IRC protocol functions and callbacks 2020-03-28 16:06:45 +01:00
Sébastien Helleu f072eb8d78 tests: add tests on function irc_protocol_get_message_tags 2020-03-28 13:40:39 +01:00
Sébastien Helleu 03ffd396a4 irc: move functions irc_protocol_get_message_tags and irc_protocol_parse_time before protocol callbacks 2020-03-28 13:39:48 +01:00
Sébastien Helleu 2efad93220 irc: remove empty lines 2020-03-28 10:36:10 +01:00
Sébastien Helleu 349251feb1 irc: fix typo in description of message 001 2020-03-27 22:51:15 +01:00
Sébastien Helleu 0834286843 irc: add examples of NOTICE and PRIVMSG messages to channel ops 2020-03-27 22:50:52 +01:00
Sébastien Helleu 4245641767 tests: add tests on function irc_protocol_cb_ping 2020-03-26 23:05:34 +01:00
Nils Görs 359253f610 doc: update German documentation 2020-03-26 11:09:12 +01:00
Sébastien Helleu b82a887f2a tests: add tests on function irc_protocol_cb_part 2020-03-25 20:48:54 +01:00
Sébastien Helleu cecbad1803 tests: add test with no arguments for AWAY command 2020-03-24 16:58:11 +01:00
Sébastien Helleu 9fac350b3f tests: add tests on IRC protocol functions with not enough arguments 2020-03-24 16:56:57 +01:00
Sébastien Helleu fa931b46eb core: fix compiler warnings on Cygwin 2020-03-23 07:23:08 +01:00
Sébastien Helleu e6723bb5a8 doc: add question about configuration for a small terminal size in FAQ 2020-03-22 19:23:37 +01:00
Sébastien Helleu dcebdd6a55 doc: fix font size in literal blocks 2020-03-22 19:10:25 +01:00
Sébastien Helleu 186a465575 doc: update German auto-generated file 2020-03-22 14:25:44 +01:00
Nils Görs c6c485df43 core: update German translations 2020-03-22 14:09:43 +01:00
Sébastien Helleu d8f57628b7 Version 2.8-rc1 2020-03-22 11:10:15 +01:00
Sébastien Helleu d2f3e98f37 core: fix C++ compiler flags with autotools 2020-03-22 11:09:27 +01:00
Sébastien Helleu 8a9b6c1554 php: add detection of PHP 7.4 in autotools
Support of PHP 7.4 was added for CMake (in commit
72b107a970) but was still missing in autotools.
2020-03-22 10:58:09 +01:00
Sébastien Helleu 5ca64fc389 ruby: fix compiler warning on third argument of function weechat_ruby_hash_foreach_cb 2020-03-22 10:29:53 +01:00
Sébastien Helleu c14d5ba004 irc: use larger buffer for message in function irc_message_split_authenticate, just in case 2020-03-21 14:31:53 +01:00
Sébastien Helleu 4480c7b7cc irc: split AUTHENTICATE message in 400-byte chunks (closes #1459) 2020-03-21 14:28:53 +01:00
Sébastien Helleu bf42a1ebc5 irc: replace "char *" by "const char *" in arguments of split functions 2020-03-21 14:27:47 +01:00
Sébastien Helleu c29b45a0f2 api: add info "auto_connect" (closes #1453) 2020-03-20 20:42:05 +01:00
Sébastien Helleu c05cb595dc doc: add note about call to "free" on result of info_get (plugin API reference) 2020-03-20 07:08:14 +01:00
Sébastien Helleu 5c1dfcbe5b tests: add tests on functions irc_protocol_cb_mode and irc_protocol_cb_nick 2020-03-19 23:01:59 +01:00
Sébastien Helleu b45d461c3a tests: add tests on functions irc_protocol_cb_kick and irc_protocol_cb_kill 2020-03-18 22:27:15 +01:00
Sébastien Helleu a709dd05a6 tests: add tests on function irc_protocol_cb_join 2020-03-17 20:54:07 +01:00
Sébastien Helleu 332a4adc26 tests: add tests on function irc_protocol_cb_chghost 2020-03-16 20:49:50 +01:00
Sébastien Helleu f33cfc89a0 doc: update German auto-generated file 2020-03-15 07:20:57 +01:00
Sébastien Helleu e3ffe8c785 irc: set channel modes to NULL instead of "+" when no modes are remaining 2020-03-15 07:19:16 +01:00
Sébastien Helleu 851d1fb00a tests: rename function run_cmd_server to server_recv 2020-03-15 07:19:16 +01:00
Sébastien Helleu 4033c55fa2 irc: add another example of MODE message 2020-03-15 07:19:16 +01:00
Sébastien Helleu 00913de02f irc: remove unused variable "modes" from function irc_bar_item_buffer_name_content 2020-03-15 07:19:16 +01:00
Nils Görs 042c8fb02f core: update German translations 2020-03-14 21:20:12 +01:00
Sébastien Helleu aa3941fee2 tests: always run callback in calls to function config_file_option_set 2020-03-13 23:12:22 +01:00
Sébastien Helleu ba70173a2e irc: fix variable name in function irc_server_connect when GnuTLS is disabled 2020-03-12 07:35:04 +01:00
Sébastien Helleu 9545d37ab0 tests: add tests on IRC protocol functions and some callbacks
Functions tested:

* irc_protocol_is_numeric_command
* irc_protocol_log_level_for_command
* irc_protocol_tags
* irc_protocol_nick_address
* irc_protocol_cb_account
* irc_protocol_cb_away
* irc_protocol_cb_001
* irc_protocol_cb_005
2020-03-11 20:53:49 +01:00
Sébastien Helleu 5f94636b91 irc: rename argument in function irc_protocol_is_numeric_command 2020-03-10 19:19:38 +01:00
Sébastien Helleu 2fe27584ff irc: return 0 in function irc_protocol_is_numeric_command if the command is NULL or empty 2020-03-10 19:15:59 +01:00
Sébastien Helleu 8a5046f0a1 irc: add support of fake servers (no I/O, for testing purposes) 2020-03-09 21:09:55 +01:00
Sébastien Helleu 3590302183 irc: copy temporary server flag in command /server copy 2020-03-08 13:56:30 +01:00
Sébastien Helleu dcd10657b1 tests: add tests on functions weecrypto_totp_generate and weecrypto_totp_validate 2020-03-05 22:21:48 +01:00
Sébastien Helleu dabf32f213 tests: add tests on functions weecrypto_hash and weecrypto_hash_pbkdf2 with NULL hash 2020-03-04 08:24:46 +01:00
Sébastien Helleu c48815673d core: update ChangeLog (issue #1455) 2020-03-03 21:51:03 +01:00
Sébastien Helleu 91fe8da039 core: add detection of Ruby 2.7 in autotools 2020-03-03 21:50:17 +01:00
Lucas Kanashiro 60e86f929d core: add detection for Ruby 2.7 2020-03-03 21:49:32 +01:00
Sébastien Helleu 4afaacd34e tests: add tests on function weecrypto_get_hash_algo 2020-03-03 21:29:44 +01:00
Sébastien Helleu 7af8e6c652 core: add minimum libgcypt version 1.7.0 for SHA3 algorithms in comment of function weecrypto_hash 2020-03-02 22:57:44 +01:00
Sébastien Helleu 8ffe9be8a7 core: fix ChangeLog entry 2020-03-02 22:57:44 +01:00
Sébastien Helleu 3604abba7d core: fix copyright date in wee-crypto sources 2020-03-02 22:57:39 +01:00
Sébastien Helleu 2d7829b2d5 core: require libgcrypt >= 1.7.0 for SHA3 algorithms 2020-03-02 21:49:30 +01:00
Sébastien Helleu c6757f642f tests: fix generation of test scripts with Python 3.8 2020-03-02 21:39:27 +01:00
Sébastien Helleu dc7f1e81fb core: add CVE ids in ChangeLog 2020-03-02 20:42:26 +01:00
Sébastien Helleu 2d2b49bfaa relay: accept hash of password in init command with option "password_hash"
Allowed algorithms are:

* PBKDF2 (SHA256 or SHA512, salt, iterations)
* SHA256
* SHA512
2020-03-02 00:46:10 +01:00
Sébastien Helleu 1882686f8a script: rename variable length_hash to hash_size 2020-03-01 23:14:55 +01:00
Sébastien Helleu 0271eacbe5 relay: rename variable length_hash to hash_size 2020-03-01 23:14:55 +01:00
Sébastien Helleu 3157d1f06e api: add function crypto_hash_pbkdf2 2020-03-01 23:14:55 +01:00
Sébastien Helleu 9a6a27ef58 core: move crypto functions to wee-crypto.c, rename API function string_hash to crypto_hash 2020-03-01 21:24:27 +01:00
Sébastien Helleu c4ef3d6c2e core: merge functions string_hash_binary and string_hash into a single function string_hash 2020-03-01 16:41:28 +01:00
Sébastien Helleu 1ae2591458 core: add function secure_hash_pbkdf2 2020-03-01 14:26:24 +01:00
Sébastien Helleu 3472793d24 script: call function string_hash in script_repo_sha512sum_file to compute SHA512 hash
This removes dependency on libgcrypt in script plugin.
2020-03-01 09:08:48 +01:00
Sébastien Helleu bb363ab27f relay: call function string_hash_binary in relay_websocket_build_handshake to compute SHA1 hash
This removes dependency on libgcrypt in relay plugin.
2020-03-01 09:03:49 +01:00
Sébastien Helleu 7449bc8827 core: add support of CRC32 algorithm in hash functions 2020-02-29 21:12:13 +01:00
Sébastien Helleu 410a5b341f api: add functions string_hash_binary and string_hash 2020-02-29 21:02:42 +01:00
Sébastien Helleu 7e808e2ef7 core: call function secure_hash_binary in secure_derive_key to compute SHA512 hash 2020-02-29 15:46:25 +01:00
Sébastien Helleu 600c43dcf5 tests: add tests on function secure_derive_key 2020-02-29 15:46:25 +01:00
Sébastien Helleu 45fd04ee72 core: return 0 in case of invalid parameters received in function secure_derive_key 2020-02-29 15:46:25 +01:00
Sébastien Helleu e2135fc3eb core: add functions to compute binary/hex hash of data 2020-02-29 15:46:25 +01:00
Sébastien Helleu 91701cbdb4 php: fix crash when loading script with PHP 7.4 (closes #1452) 2020-02-28 21:28:29 +01:00
Nils Görs 3f67cfecc8 django.po: Update German translations 2020-02-26 15:38:23 +01:00
Sébastien Helleu 5655778afa core: update stable version in version.sh 2020-02-21 16:09:22 +01:00
Sébastien Helleu ff4e9d6e69 core: add version 2.7.1 in release notes 2020-02-20 22:17:05 +01:00
Sébastien Helleu a4fcd5570f core: add version 2.7.1 in ChangeLog 2020-02-20 22:14:28 +01:00
Sébastien Helleu 7352ddfcf0 build: ignore file usr/share/applications/weechat.desktop in Cygwin build 2020-02-20 22:09:12 +01:00
Sébastien Helleu 6daa09b0b8 script: fix memory leak in read of script repository file if it has invalid content 2020-02-18 21:04:21 +01:00
Sébastien Helleu c6e9e18aaa script: fix unexpected display of scripts list in buffer with command /script list -i 2020-02-16 08:04:58 +01:00
Sébastien Helleu 3fc0f1957e script: remove dead assignment of variable length in function script_action_list_input 2020-02-16 07:59:02 +01:00
Sébastien Helleu 4cb0e2dc55 doc: update auto-generated files 2020-02-15 07:39:41 +01:00
Nils Görs 774345cea9 core: update German translations 2020-02-14 18:54:36 +01:00
Sébastien Helleu 09aa6dbf06 core: add CVE-2020-8955 in ChangeLog 2020-02-14 07:41:56 +01:00
Sébastien Helleu 230f648584 irc: use irc_server_prefix_chars_default if server->prefix_chars is NULL 2020-02-10 21:18:47 +01:00
Sébastien Helleu 9904cb6d2e irc: fix crash when receiving a malformed message 352 (who)
Thanks to Stuart Nevans Locke for reporting the issue.
2020-02-10 07:37:11 +01:00
Sébastien Helleu 40ccacb433 irc: fix crash when a new message 005 is received with longer nick prefixes
Thanks to Stuart Nevans Locke for reporting the issue.
2020-02-09 20:04:45 +01:00
Sébastien Helleu 5edbeea338 core: fix unlikely memory leak in completion 2020-02-09 06:56:53 +01:00
Sébastien Helleu 7fde75797c doc: remove reference to obsolete script shell.py in FAQ 2020-02-08 21:59:14 +01:00
Sébastien Helleu 40e8e928cd doc: add question about timezone in FAQ 2020-02-08 21:59:14 +01:00
Sébastien Helleu 6f4f147d8e irc: fix crash when receiving a malformed message 324 (channel mode)
Thanks to Stuart Nevans Locke for reporting the issue.
2020-02-08 20:24:50 +01:00
Sébastien Helleu 39f2591cf5 tests: add tests on ANSI default text/background colors 2020-02-08 10:29:07 +01:00
Sébastien Helleu 2769989751 irc: remove nested switches in function irc_color_decode_ansi_cb 2020-02-07 21:29:46 +01:00
Sébastien Helleu b8d7af54e3 doc: add keys and actions on fset and script buffers in user's guide 2020-02-06 21:17:54 +01:00
Sébastien Helleu 60f2734184 irc: use dynamic string in function irc_color_encode 2020-02-05 21:51:11 +01:00
Sébastien Helleu 5b902eb804 irc: replace realloc by dynamic string in function irc_color_decode 2020-02-05 21:50:39 +01:00
Sébastien Helleu 6f69d98ee9 core: fix typo in French translation of /help fset 2020-02-04 22:04:18 +01:00
Sébastien Helleu 84648a5cd8 tests: add eval tests with debug enabled 2020-02-04 20:56:59 +01:00
Sébastien Helleu 15f7d7aeb1 core: update ChangeLog 2020-02-03 21:41:25 +01:00
Sébastien Helleu f76a5a8b57 tests: add unit tests on function util_file_get_content 2020-02-03 21:39:06 +01:00
Sébastien Helleu 3edae5af86 tests: add unit tests on function util_get_time_diff 2020-02-02 13:58:35 +01:00
Sébastien Helleu 27266ccd02 core: rename function util_get_uptime to util_get_time_diff
The two times must be sent as parameters, which makes the function not specific
to uptime. It is now easier to test the function in unit tests.
2020-02-02 13:57:39 +01:00
Sébastien Helleu 4e2718d234 irc: add nick changes in the hotlist (except self nick change) 2020-02-01 23:02:55 +01:00
Sébastien Helleu 95e34c71d6 core: update ChangeLog (issue #1442) 2020-01-30 22:07:32 +01:00
orbea 6d2d304136 Fix the build with guile-3.0.0.
v2: Update configure.ac too.

Signed-off-by: orbea <orbea@riseup.net>
2020-01-30 22:05:43 +01:00
Sébastien Helleu d2dda92daf tests: add eval tests with hdata variables of different types 2020-01-27 23:04:24 +01:00
Sébastien Helleu b7c09ed084 tests: add eval tests on conditions with text after closing parenthesis 2020-01-27 23:04:24 +01:00
Sébastien Helleu a6a6fb74c2 tests: add eval tests on conditions with leading and trailing spaces (ignored) 2020-01-27 23:04:24 +01:00
Sébastien Helleu 2839dc7ddf tests: add eval tests on "regex not matching" comparison 2020-01-27 23:04:24 +01:00
Sébastien Helleu 0975c407e0 tests: add eval tests with hdata list name and pointer 2020-01-27 23:04:24 +01:00
Sébastien Helleu 201b4da169 tests: add eval tests with buffer local variables 2020-01-27 23:04:24 +01:00
Sébastien Helleu 8107b5d162 tests: add eval tests on options with different types 2020-01-27 23:04:24 +01:00
Sébastien Helleu dd13393896 tests: add eval test with empty value for "date:" 2020-01-27 23:04:24 +01:00
Sébastien Helleu 70f0c81a2c tests: add eval tests with invalid values for "modifier:" 2020-01-27 23:04:24 +01:00
Sébastien Helleu 6d9a247df3 tests: add eval tests with invalid values for "repeat:" 2020-01-27 23:04:24 +01:00
Sébastien Helleu 1914ceb74f tests: add eval tests with invalid values for "cut:" and "cutscr:" 2020-01-27 23:04:22 +01:00
Sébastien Helleu 34bb43379a tests: add eval test with invalid value for "hide:" 2020-01-27 21:21:01 +01:00
Sébastien Helleu 070e86bd6e tests: add eval test with invalid regex group 2020-01-27 21:17:17 +01:00
Sébastien Helleu 1d77b9742e tests: add evaluation tests with ternary operator and escape of prefix ("$") 2020-01-27 21:09:54 +01:00
Sébastien Helleu d91d1ebb8c tests: add other calc tests with multiple operators
The order of operators are different from the initial test, so this increases
the code coverage in wee-calc.c.
2020-01-27 20:54:23 +01:00
Sébastien Helleu f980820395 logger: fix crash when disabling logging on a buffer (closes #1444)
Crash happens if the log file was deleted before disabling logging and if the
option logger.file.info_lines is on.
2020-01-25 13:42:12 +01:00
Sébastien Helleu 4d67af399d core: flush stdout/stderr before forking in hook_process function (closes #1441) 2020-01-20 21:15:15 +01:00
Sébastien Helleu 7cd566e8d3 core: reset variable "old_full_name" after send of signal "buffer_renamed" (issue #1428) 2020-01-12 17:09:47 +01:00
Sébastien Helleu b79cd6d546 relay: update buffers synchronization when buffers are renamed (closes #1428) 2020-01-12 17:03:16 +01:00
Sébastien Helleu 1fac6fd404 core: add variable "old_full_name" in buffer, set before the buffer is renamed (issue #1428) 2020-01-12 16:57:08 +01:00
Sébastien Helleu 4f9c4fecd3 irc: case-insensitive comparison on incoming CTCP command, force upper case on CTCP replies (closes #1439) 2020-01-11 11:02:41 +01:00
Sébastien Helleu 4f42f407c1 doc: remove space in example of hsignal irc_redirect_command (plugin API reference) 2020-01-05 09:15:40 +01:00
Sébastien Helleu 9ac4639c8c xfer: send signal "xfer_ended" after the received file has been renamed (closes #1438) 2020-01-04 11:19:47 +01:00
Sébastien Helleu feb6258910 core: update copyright dates 2020-01-04 10:41:26 +01:00
Sébastien Helleu 481da803cb buflist: add pointer "window" in bar item evaluation 2019-12-26 22:44:19 +01:00
Sébastien Helleu e11075e2cd doc: update German auto-generated file 2019-12-23 22:14:33 +01:00
Nils Görs cc7ac1284d core: update German translations 2019-12-23 20:00:02 +01:00
Sébastien Helleu 330149b9b6 relay: reject client with weechat protocol if password or totp is received in init command but not set in WeeChat (closes #1435) 2019-12-21 10:47:35 +01:00
Sébastien Helleu e612e63140 core: fix evaluation of condition with nested "if" (closes #1434) 2019-12-18 21:22:36 +01:00
Sébastien Helleu a13099aa63 core: add debug option "-d" in command /eval (issue #1434) 2019-12-18 21:18:59 +01:00
Sébastien Helleu 7e833ee60b core: add missing variable "proxy" in function hook_connect_print_log 2019-12-18 07:55:39 +01:00
Sébastien Helleu 72da71880c doc: update German auto-generated files 2019-12-15 21:22:51 +01:00
Nils Görs b341432887 core: update German translations 2019-12-15 21:17:33 +01:00
Sébastien Helleu bb62485aa9 irc: fix memory leak when the channel topic is changed 2019-12-15 07:27:45 +01:00
Sébastien Helleu 72b107a970 php: add detection of PHP 7.4 2019-12-14 11:25:07 +01:00
Sébastien Helleu 019bc79b0f core: update ChangeLog (issue #1433) 2019-12-13 21:34:01 +01:00
Sébastien Helleu 517bdaa4a8 core: update translations (issue #1433) 2019-12-13 21:33:48 +01:00
Sébastien Helleu 00485af7c9 core: add contributor in AUTHORS.adoc (issue #1433) 2019-12-13 21:31:30 +01:00
Matthew Horan f966329862 api: add info "weechat_headless" 2019-12-13 21:30:54 +01:00
Sébastien Helleu 5ae0485404 core: fix version in ChangeLog 2019-12-13 21:27:02 +01:00
Sébastien Helleu 60fa5a7555 core: update ChangeLog (issue #1431) 2019-12-13 21:22:45 +01:00
Sébastien Helleu 8d107912d6 core: update translations 2019-12-13 21:21:02 +01:00
Simmo Saan c487965e8b irc: add GnuTLS >= 3.1.0 requirement to ssl_password option help (issue #115) 2019-12-13 21:18:22 +01:00
Simmo Saan 139a7053e4 irc: fix compilation with GnuTLS < 3.1.0 (issue #115)
Due to this ssl_password will be partially unused with GnuTLS < 3.1.0.
In that case an encrypted SSL client cert import will simply fail.
2019-12-13 21:18:22 +01:00
Sébastien Helleu 9c227de6bf core: add directory /usr/share/applications/ in cygwin package "weechat" 2019-12-08 15:56:23 +01:00
Sébastien Helleu da28c392ea Version 2.8-dev 2019-12-08 10:18:33 +01:00
Sébastien Helleu 236dbe3f62 Version 2.7 2019-12-08 09:48:53 +01:00
Sébastien Helleu 632755d51d core: remove obsolete file FindTCL.cmake from root Makefile.am 2019-12-08 09:23:35 +01:00
Sébastien Helleu ee52c8ceae debian: fix debian/wheezy and ubuntu/trusty patches 2019-12-08 09:13:46 +01:00
Sébastien Helleu dda3ac7963 debian: update changelog 2019-12-08 08:23:07 +01:00
Sébastien Helleu e81d0787e4 debian: bump Standards-Version to 4.4.0 2019-12-08 08:22:45 +01:00
Sébastien Helleu 54aa8b82b3 doc: update Polish auto-generated files 2019-12-01 18:03:07 +01:00
Krzysztof Korościk 39ae55322d doc: updated polish traslation 2019-12-01 17:14:12 +01:00
Krzysztof Korościk 10f4e16695 po: update polish translation 2019-12-01 16:24:32 +01:00
Sébastien Helleu cfd7d31f95 doc: update German auto-generated files 2019-12-01 11:42:49 +01:00
Nils Görs 621b87ea8a core: update German translations 2019-11-29 09:17:37 +01:00
Sébastien Helleu c947d1575f core: exit makedist.sh script if command "cd" failed 2019-11-28 21:28:07 +01:00
Sébastien Helleu d876ec49fc core: replace "! -z" by "-n" in build-debian.sh 2019-11-28 21:27:43 +01:00
Sébastien Helleu d2300e62af core: replace "-o" by "||" in tools scripts 2019-11-28 21:26:45 +01:00
Sébastien Helleu a727516e0d core: run command and check return code on same line in tools scripts 2019-11-28 21:25:47 +01:00
Sébastien Helleu c0e48b0370 core: double quote variables in tools scripts 2019-11-28 21:23:59 +01:00
Sébastien Helleu 45509c3560 core: double quote variables in script autogen.sh 2019-11-27 20:17:48 +01:00
Sébastien Helleu fb8f0590b0 Version 2.7-rc1 2019-11-26 20:10:18 +01:00
Sébastien Helleu 3dab07d659 tests: add unit tests on hash algorithms with salt (issue #635) 2019-11-25 23:02:05 +01:00
Sébastien Helleu cd53fc61cf core: fix typo in French translation (issue #635) 2019-11-25 22:43:55 +01:00
Sébastien Helleu d66a02ca9d core: move each hash algorithm in a separate function (issue #635) 2019-11-25 22:31:36 +01:00
Sébastien Helleu 771b932dec doc: update auto-generated files with WeeChat options (issue #635) 2019-11-25 21:44:27 +01:00
Sébastien Helleu 41911babd3 core: remove obsolete translations 2019-11-25 21:42:57 +01:00
Sébastien Helleu f69079e3d0 core: update ChangeLog (issue #635) 2019-11-25 21:39:02 +01:00
Sébastien Helleu b43ab911fd core: add more info in /help weechat.look.nick_color_hash_salt (issue #635) 2019-11-25 21:38:58 +01:00
Sébastien Helleu 0044fa1902 core: remove allocation of string when salt is used (issue #635) 2019-11-25 21:38:55 +01:00
Simmo Saan 1a00368888 core: add option weechat.look.nick_color_hash_salt to allow for reshuffling of colors (issue #635) 2019-11-25 21:38:20 +01:00
Sébastien Helleu c634d6c56e doc: list the things removed by WeeChat on /plugin unload (user's guide) 2019-11-24 09:40:53 +01:00
Sébastien Helleu 661ef1e653 doc: fix translations in French plugin API reference 2019-11-24 09:32:35 +01:00
Sébastien Helleu 8223263e0e doc: remove flags "translation missing" in French docs 2019-11-24 09:29:02 +01:00
Sébastien Helleu a843e8fb14 doc: bump version of documentation generator 2019-11-22 21:01:14 +01:00
Sébastien Helleu e1692ab7e9 doc: add function to print counters, add separator lines (documentation generator) 2019-11-22 21:00:58 +01:00
Sébastien Helleu 73b3ff1491 doc: simplify function to compute SHA256 checksum, move function outside class AutogenDoc (documentation generator) 2019-11-22 20:59:58 +01:00
Sébastien Helleu 178b3eb8a6 doc: sort locales in documentation generator 2019-11-22 20:59:06 +01:00
Sébastien Helleu 2f99033384 doc: remove path option in documentation generator 2019-11-22 20:57:59 +01:00
Sébastien Helleu f1641604b0 doc: remove obsolete ignored options/completions in documentation generator 2019-11-22 20:57:52 +01:00
Sébastien Helleu e743e731ec irc: do not automatically open a channel with name "0" (closes #1429)
"0" is a special channel name which causes a client to leave all the channels
it is presently on.

Note that when option irc.look.buffer_open_before_join is on, WeeChat may still
open channel buffers with an invalid channel name like "1".  The server should
reply something like that, displayed on the server buffer:

  1: No such channel
2019-11-21 20:35:32 +01:00
Sébastien Helleu 64aae8b959 core: update build directories in .gitignore 2019-11-19 07:40:11 +01:00
Sébastien Helleu e4a9f95e38 core: remove arguments for endforeach() in CMake files 2019-11-18 20:18:54 +01:00
Sébastien Helleu 7aa24ecd88 core: add different icons sizes (16x16 to 512x512) (closes #1347) 2019-11-18 20:05:43 +01:00
Sébastien Helleu 8cde654c6f core: set buffer name, short name and title only if the value has changed
This fix reduces the number of messages "_buffer_title_changed" sent to the
weechat relay clients in IRC private buffers (this message was sent for every
new message received in the private buffer).
2019-11-17 21:48:17 +01:00
Sébastien Helleu 9a40aa04f8 core: rename label "enhancement" to "feature" 2019-11-15 21:06:15 +01:00
Sébastien Helleu 3a03184d7a irc: mention /filter command in /help irc.look.smart_filter 2019-11-15 08:38:40 +01:00
Sébastien Helleu b5804bd64d core: add labels in GitHub issue templates 2019-11-14 07:24:54 +01:00
Sébastien Helleu 005e5fd8f5 core: fix French translation of "uptime" 2019-11-13 21:17:14 +01:00
Sébastien Helleu fe7a05cb1f core: update ChangeLog 2019-11-12 21:20:43 +01:00
Eli Schwartz 76c6f52e8c build: support python 3.8
In python 3.8, in order to link to -lpython3.8, you need to use the
exported pkg-config interface 'python3-embed' (or 'python3-config --libs
--embed'), see https://bugs.python.org/issue36721 for details.
2019-11-12 21:19:47 +01:00
Eli Schwartz 5c8ac69f73 python: use more idiomatic cmake pkg-config linking
cmake documentation is absolutely atrocious, and I don't know why they
mention all the wrong things to use, and the cargo cult of successfully
writing a cmake build definition (copy-pasting what works from other
projects) also uses all the wrong things. But it turns out it is
possible to correctly link a PkgConfig target despite all that, at
least, *iff* you use cmake >= 3.13. I've chosen option 2, which is to
vendor in cmake >= 3.13's FindPkgConfig module in the previous commit.

Using IMPORTED_TARGET GLOBAL in a pkg-config check will result in a
proper linker target being created. For comparison, this is like using
meson's dependency() target, except meson forces you to do this by
default. The result is that the build system's internal representation
of how to link something, is used instead of manually passing build
flags defined in variables.

This is an important distinction to make, because cmake does not have a
list datatype, and instead turns lists into strings separated by ';'
which are indistinguishable from, like, strings which contain ';'
characters. When you pass the resulting list-which-isn't-really-a-list
to link an executable/library, you either need to preprocess the
variable to replace ';' with ' ' (just in case there are multiple
elements) or use cmake functions which magically know to do this
themselves -- or at least, I assume there are cmake functions that
correctly handle so-called "lists", or there would be no need for
"lists" to exist.

The IMPORTED_TARGET will define a bunch of INTERFACE_* properties which
do seem to do exactly this. The resulting build definition should
actually, correctly, link python, thereby fixing #1398 in a better way.
2019-11-12 21:19:47 +01:00
Eli Schwartz 682e558f76 cmake: vendor in a new version of FindPkgConfig
The current one is anciently ancient, and dates back to commit
4d2925ef1c which vendored this "for old
versions of cmake". Well, currently it just stops using new versions of
FindPkgConfig, so we're stuck on the 2006 version from cmake 2.5.0.

Instead of deleting it entirely (the minimum version of cmake is
currently 3.0) make this vendored file continue to be useful by using it
to vendor in the latest version of FindPkgConfig from cmake 3.16.0-rc3
with a bunch of useful improvements.
2019-11-12 21:19:47 +01:00
Sébastien Helleu a36e17abf9 debian: disable javascript plugin on Debian Sid and Ubuntu Eoan 2019-11-11 08:38:05 +01:00
Sébastien Helleu 38bb297d91 core: update ChangeLog (issue #1420) 2019-11-10 11:06:49 +01:00
Sébastien Helleu 421d6481da core: link with libnetwork and not libpthread on Haiku (autotools) (issue #1420) 2019-11-10 11:06:39 +01:00
Jerome Duval 8d991f1284 Haiku: link libnetwork, not libpthread. 2019-11-10 11:04:47 +01:00
Sébastien Helleu 9f8162651f irc: set option irc.look.display_pv_warning_address to off by default (issue #892)
This is because the bitlbee server causes the warning to be displayed when it
is not expected (the address of remote nick changes multiple times on login).
2019-11-08 21:27:12 +01:00
Sébastien Helleu 17d3032b73 core: move line from "New features" to "Bug fixes" 2019-11-07 19:46:55 +01:00
Sébastien Helleu 90aec7bec7 core: update URL of WeeChat blog 2019-11-05 07:50:30 +01:00
Sébastien Helleu 07577194c5 doc: add examples of division in ${calc:...} (plugin API reference) 2019-11-04 19:01:31 +01:00
Sébastien Helleu 9264de9ce0 doc: fix list of "updated in" versions in function string_eval_expression (plugin API reference) 2019-11-04 18:59:32 +01:00
Sébastien Helleu 4f7a51f72b core: fix sentence in release notes 2019-11-03 21:10:48 +01:00
Sébastien Helleu 6507544947 irc: fix typo and examples in /help server 2019-11-03 14:54:45 +01:00
Nils Görs cdcbdc94e0 core: update German translations 2019-11-03 14:48:43 +01:00
Sébastien Helleu 10f85df867 irc: set raw filter to "*" if local variable "filter" was not set after /upgrade on raw buffer 2019-11-03 09:55:09 +01:00
Sébastien Helleu 7e07954fbf irc: restore irc raw filter after /upgrade (issue #1000) 2019-11-03 09:28:16 +01:00
Sébastien Helleu 015ae4a94b irc: add filters on raw buffer (closes #1000) 2019-11-03 09:01:44 +01:00
Sébastien Helleu 4a86ab55d8 fset: add comment on filter by evaluated expression 2019-10-30 19:41:56 +01:00
Sébastien Helleu 7cac32fc1f fset: fix filter variable used to match filter string 2019-10-30 19:41:31 +01:00
Sébastien Helleu c6161d0e4a plugins: sort options added in configuration sections 2019-10-23 19:45:06 +02:00
Sébastien Helleu ecc7edda9e core: optimize search of options in configuration sections
Since options are sorted in sections, it is faster to search from the last
option to the first one.

For configuration files with many options in a single section (like
plugins.conf), the load of configuration file is about 2 to 3x faster.
2019-10-23 19:45:06 +02:00
Sébastien Helleu fbc9faed42 doc: add keys to type for the example message with color codes (user's guide) 2019-10-22 07:54:50 +02:00
Sébastien Helleu c99889cb15 core: fix typo in French translation of /help fset 2019-10-21 19:14:31 +02:00
Sébastien Helleu f85f097c25 debian: disable javascript plugin on Ubuntu Focal 2019-10-20 21:27:21 +02:00
Sébastien Helleu 5d4220a91f core: fix scrolling up in bare mode when switched to bare mode at the top of the buffer (closes #899, issue #978) 2019-10-14 20:44:15 +02:00
Sébastien Helleu 7e6d933d74 doc: update German auto-generated file 2019-10-13 21:05:32 +02:00
Nils Görs 92853e1b47 core: update German translations 2019-10-13 18:54:48 +02:00
Sébastien Helleu 577a932201 core: add info about Python 3 and strings in release notes 2019-10-13 08:18:38 +02:00
Sébastien Helleu 899550ca94 doc: fix typo in scripting guide 2019-10-13 08:18:30 +02:00
Sébastien Helleu ab6a991de2 doc: fix language in links to plugin API reference (scripting guide) 2019-10-12 23:26:16 +02:00
Sébastien Helleu 2dbc283023 doc: add links on signals and hsignals (plugin API reference) 2019-10-12 23:17:33 +02:00
Sébastien Helleu 513f5a1ee7 python: send "bytes" instead of "str" to callbacks in Python 3 when the string is not UTF-8 valid (issue #1220, closes #1389) 2019-10-12 22:21:48 +02:00
Sébastien Helleu 8fc8f728d4 core: add reverse of string for screen in evaluation of expressions with "revscr:" 2019-10-12 20:14:36 +02:00
Sébastien Helleu 9535f4a70b doc: update German auto-generated file 2019-10-11 22:45:08 +02:00
Nils Görs f85adf5cf1 core: update German translations 2019-10-11 22:41:19 +02:00
Sébastien Helleu 876a0a1609 irc: add option irc.look.display_pv_warning_address (closes #892)
If the address of remote nick changes in a private buffer, a warning is
displayed.
2019-10-11 20:26:34 +02:00
Sébastien Helleu 1dda5ffd02 doc: add value -1 for notify level in function hook_line (plugin API reference) 2019-10-10 18:39:31 +02:00
Sébastien Helleu dc9964ccc6 irc: add server option "ssl_password" (issue #115, issue #1416) 2019-10-09 21:40:43 +02:00
Sébastien Helleu 37415e61d5 core: update translations (issue #115, issue #1416) 2019-10-09 21:39:25 +02:00
Simmo Saan 116150c2fc irc: add server option ssl_password for SSL certificate private key password (closes #115) 2019-10-09 21:37:41 +02:00
Sébastien Helleu 5398f5d566 irc: fix compiler warning on uninitialized variable 2019-10-09 07:17:32 +02:00
Nils Görs 02c63beef9 core: add German translations in weechat.desktop 2019-10-08 20:54:25 +02:00
Sébastien Helleu 6619219297 doc: add value -1 for notify level in trigger of type line (user's guide) 2019-10-08 20:30:59 +02:00
Sébastien Helleu 6fa0f49a28 core: update ChangeLog (issue #982, issue #408) 2019-10-07 21:06:55 +02:00
Sébastien Helleu afe64aefbf core: add keywords in weechat.desktop (issue #982, issue #408) 2019-10-07 21:06:55 +02:00
Sébastien Helleu 85f9ead7b8 core: add French translations in weechat.desktop (issue #982, issue #408) 2019-10-07 21:06:55 +02:00
Sébastien Helleu b35c94cc91 core: install weechat.desktop with autotools (issue #982, issue #408) 2019-10-07 21:06:50 +02:00
Lucas Hoffmann 8054cb0ee1 core: add a desktop file (closes #982, closes #408) 2019-10-07 20:47:43 +02:00
Sébastien Helleu cbeecc0cde core: ensure completion_item is not NULL before using it 2019-10-06 21:47:56 +02:00
Sébastien Helleu 528c769e71 core: fix crash in completion of filenames 2019-10-06 21:45:27 +02:00
Sébastien Helleu d2a63b2b44 doc: update German auto-generated files 2019-10-06 19:17:15 +02:00
Sébastien Helleu 86e623a554 doc: fix chapter on IRC server connection in quickstart guide 2019-10-06 19:12:47 +02:00
Sébastien Helleu c391fe5fa5 core: update ChangeLog (closes #630) 2019-10-06 19:11:15 +02:00
Sébastien Helleu c3b33859ae core: fix long lines 2019-10-06 19:09:29 +02:00
Sébastien Helleu f2551b8403 Merge remote-tracking branch 'origin/pr/630' 2019-10-06 19:07:25 +02:00
Sébastien Helleu 98d9dc1a03 core: update ChangeLog (closes #610, closes #617, closes #619) 2019-10-06 18:14:50 +02:00
Sébastien Helleu e6570d6e3a core: fix line too long, add comment on argument "with_suffix" 2019-10-06 18:11:58 +02:00
Sébastien Helleu e47002884a core: count suffix in alignment computed for context info 2019-10-06 18:08:52 +02:00
Sébastien Helleu c77bccba87 Merge remote-tracking branch 'origin/pr/619' 2019-10-06 18:08:17 +02:00
Sébastien Helleu af5951c123 Merge pull request #1415 from ingank/doc-de-improve-pr
doc: update German documentation
2019-10-06 17:25:00 +02:00
Ingolf Ankert 1eb54f4065 doc: update German documentation
Reviewed: from @flashcode
2019-10-06 17:14:07 +02:00
Sébastien Helleu de0209e6d6 Merge pull request #1414 from ingank/improve-po-de
core: update German translations
2019-10-06 17:03:27 +02:00
Ingolf Ankert 903cb0baf3 doc: update German documentation
fix: typos in doc/de/weechat_faq.de.adoc
fix: typos, spelling, grammar in doc/de/weechat_quickstart.de.adoc
2019-10-06 16:55:26 +02:00
Ingolf Ankert 5518b56561 core: update German translations 2019-10-06 15:53:57 +02:00
Sébastien Helleu 53360a7909 logger: fix write in log file if it has been deleted or renamed (closes #123) 2019-10-06 13:36:35 +02:00
Sébastien Helleu 529af39612 doc: translate description of logger masks in user's guide 2019-10-06 10:19:01 +02:00
Sébastien Helleu 79e124d6e4 Merge pull request #1413 from FiXato/patch-2
Added introductory description of Logger masks
2019-10-06 10:18:32 +02:00
Sébastien Helleu d3254262ac doc: fix styles in plugin API reference 2019-10-06 10:01:49 +02:00
Sébastien Helleu 587f5bf15b irc: use path from option xfer.file.upload_path to complete filename in command "/dcc send" (closes #60) 2019-10-06 09:38:52 +02:00
Sébastien Helleu 6e382d26a9 core: add optional default path (evaluated) in completion "filename" (issue #60) 2019-10-06 09:38:20 +02:00
Sébastien Helleu 88aa82d672 core: add support of modifiers in evaluation of expressions with "modifier:name,data,string" (issue #60) 2019-10-06 09:13:35 +02:00
Sébastien Helleu 1a0ba4a9dc api: add modifier "eval_path_home" (issue #60) 2019-10-06 09:06:55 +02:00
Sébastien Helleu e921b9f432 core: fix comments on modifier callback functions in plugin API 2019-10-06 08:56:12 +02:00
Filip H.F. "FiXato" Slagter 86dcbc09c0 Added introductory description of Logger masks
While the documentation for Logger filename masks contained examples, it didn't actually describe it would try to match in order of descending specificity.
2019-10-05 20:43:29 +02:00
Sébastien Helleu 587ddf7222 core: add reference to issue #66 for hook_line function in ChangeLog 2019-10-05 18:55:27 +02:00
Sébastien Helleu c521392207 core: add quotes around commands with arguments in ChangeLog 2019-10-05 18:18:07 +02:00
Sébastien Helleu 1da5b9126e core: fix typo in ChangeLog 2019-10-05 18:17:49 +02:00
Sébastien Helleu 3c0bdc18f3 xfer: add option xfer.file.download_temporary_suffix with default value ".part" (closes #1237) 2019-10-05 18:11:39 +02:00
Sébastien Helleu 6c23f632b1 xfer: fix memory leak when a xfer is freed and when the plugin is unloaded 2019-10-05 17:49:07 +02:00
Sébastien Helleu 3e189fa60d irc: fix typo in /help links 2019-10-04 20:44:09 +02:00
Sébastien Helleu f9dcb573ca doc: update German auto-generated files 2019-10-03 20:39:48 +02:00
Sébastien Helleu 8c31306f30 Merge pull request #1410 from ingank/ingank/german-translation
core: update German translations
2019-10-03 20:32:37 +02:00
Sébastien Helleu d2be0e8e1d Merge pull request #1409 from ingank/master
doc: update German documentation
2019-10-03 20:32:10 +02:00
Ingolf Ankert b03a4e192c core: update German translations 2019-10-03 15:25:42 +02:00
Sébastien Helleu 70fd722278 logger: add option logger.file.color_lines (closes #528, closes #621) 2019-10-02 20:44:12 +02:00
Ingolf Ankert f3376f4264 doc: update German documentation 2019-10-01 21:48:44 +02:00
Sébastien Helleu e386965aba api: add modifier "color_encode_ansi" (issue #528) 2019-10-01 18:31:41 +02:00
Sébastien Helleu 90f711a965 core: add function to convert WeeChat colors to ANSI colors (issue #528) 2019-10-01 18:31:41 +02:00
Sébastien Helleu 177fa6c528 core: add support of reverse video in ANSI color codes 2019-10-01 18:31:41 +02:00
Sébastien Helleu a8ca4b5b3a tests: add tests on GUI color functions 2019-10-01 18:31:41 +02:00
Sébastien Helleu daad558291 core: fix typos in comments 2019-10-01 18:31:41 +02:00
Sébastien Helleu baf8f635ff core: fix style in CMake files 2019-10-01 18:31:41 +02:00
Sébastien Helleu 779420d50d core: fix typo in ChangeLog 2019-10-01 18:29:59 +02:00
Sébastien Helleu 92cad366a2 core: fix typos in French translations 2019-09-30 21:46:56 +02:00
Sébastien Helleu cddb314a10 doc: update German auto-generated files 2019-09-28 15:06:11 +02:00
Ingolf Ankert 45a55895fb core: update German translations 2019-09-28 14:42:32 +02:00
Sébastien Helleu 2067136506 core: add contributor in AUTHORS.adoc (issue #1406) 2019-09-27 20:56:17 +02:00
Sébastien Helleu 41cf758864 core: update ChangeLog (issue #1406) 2019-09-27 20:56:17 +02:00
Kyle Sabo 0678e0c9b3 core: fix build on Alpine (closes #1406) 2019-09-27 20:56:09 +02:00
Sébastien Helleu ae38b11407 irc: add "user" in output of irc_message_parse (closes #136) 2019-09-27 20:52:00 +02:00
Sébastien Helleu 3f33b327b1 logger: move logger backlog functions to logger-backlog.c 2019-09-26 21:26:23 +02:00
Sébastien Helleu 8ab6422520 debian: switch to Guile 2.2 in Debian build
Guile 2.2 is now used by default in Debian/Ubuntu builds, except on these old
distribution versions where only Guile 2.0 is available:

- Debian Stretch
- Debian Jessie
- Debian Wheezy
- Ubuntu Xenial
- Ubuntu Trusty
2019-09-25 20:58:22 +02:00
Nils Görs 4b0e6d5da2 core: update German translations 2019-09-24 21:43:30 +02:00
Sébastien Helleu 3a356f109f core: add power operator "**" in calc expressions (issue #997) 2019-09-24 21:03:56 +02:00
Sébastien Helleu 7d795c4d53 core: fix wrong results with the unary minus in calc expressions 2019-09-24 20:49:48 +02:00
Sébastien Helleu dc5e334f5c doc: update German auto-generated file 2019-09-23 23:10:40 +02:00
Nils Görs aa45748bff core: update German translations 2019-09-23 22:07:41 +02:00
Sébastien Helleu fe193a350b core: update translations (issue #683) 2019-09-23 21:31:09 +02:00
Simmo Saan e437613acb irc: add separate options for kick/kill message coloring (closes #683)
Add new options irc.color.message_kick and irc.color.reason_kick to be used
for coloring KICK and KILL messages.
2019-09-23 21:22:49 +02:00
Sébastien Helleu c5ffc3917f doc: update German auto-generated files 2019-09-22 21:37:23 +02:00
Nils Görs 6942444a2b core: update German translations 2019-09-22 21:32:46 +02:00
Sébastien Helleu 39b6fb6137 irc: remove option irc.network.channel_encode, add server option "charset_message" (closes #832)
This new option controls which part of the IRC message is decoded/encoded to
the target charset, and the new default behavior is to decode/encode the whole
IRC message (behavior in WeeChat >= 1.3 was to decode/encode only the text by
default).
2019-09-22 20:41:00 +02:00
Sébastien Helleu 12ee9cb75c core: build with Guile 2.2 on Cygwin (issue #1098) 2019-09-21 15:54:12 +02:00
Sébastien Helleu bed26f42a1 core: remove detection of Ruby 1.8, since Ruby >= 1.9.1 is now required (issue #1404) 2019-09-21 15:42:23 +02:00
Sébastien Helleu fbb0e85525 core: update ChangeLog (closes #1098) 2019-09-21 14:53:52 +02:00
Sébastien Helleu afce4804f5 guile: disable "/guile eval" as this does not (yet) work with Guile >= 2.2 (issue #1098) 2019-09-21 14:48:09 +02:00
Sébastien Helleu 387a44f5ec guile: add support of Guile 2.2 (issue #1098) 2019-09-21 14:48:05 +02:00
Sébastien Helleu e1a4612797 core: ignore color codes in ${length:xxx} and ${lengthscr:xxx} 2019-09-21 13:54:36 +02:00
Nils Görs de45636388 core: update German translations 2019-09-21 08:31:40 +02:00
Sébastien Helleu dcfc4e8ed5 core: add "length:xxx" and "lengthscr:xxx" in evaluation of expressions 2019-09-21 07:56:21 +02:00
Nils Görs 1919f23c2d core: update German translations 2019-09-20 23:13:03 +02:00
Sébastien Helleu bd3f1b5f00 doc: add file test-core-calc.cpp in developer's guide 2019-09-20 21:42:44 +02:00
Sébastien Helleu 92ecbe29ae core: move bugs below new features in ChangeLog 2019-09-20 21:37:21 +02:00
Sébastien Helleu 997894edc0 core: add calculation of expression in evaluation of expressions with "calc:..." (issue #997) 2019-09-20 21:37:01 +02:00
Sébastien Helleu 0109c51937 core: add chapter about CMake fatal errors on missing dependencies in release notes 2019-09-20 09:25:26 +02:00
Sébastien Helleu a81d266b31 doc: update auto-generated files 2019-09-20 09:25:03 +02:00
Nils Görs 4fca523b17 core: update German translations 2019-09-19 21:56:38 +02:00
Sébastien Helleu 5cf419dd63 core: remove extra spaces in arguments of /help uptime and /help version 2019-09-19 21:25:27 +02:00
Sébastien Helleu 85f6c5eeda script: add options "-ol" and "-il" in command /script, display "No scripts loaded" if no scripts are loaded 2019-09-19 21:20:55 +02:00
Sébastien Helleu 8a3ffda0a2 doc: set minimum Ruby version to 1.9.1 in user's guide (closes #1404)
This is now required after the changes introduced by commit
156d855787 in version 2.6.
2019-09-18 21:18:40 +02:00
Sébastien Helleu e04c30f00b doc: update German auto-generated files 2019-09-18 13:58:56 +02:00
Nils Görs 4324ff7c4b Merge branch 'master' of github.com:weechat/weechat 2019-09-18 13:52:31 +02:00
Nils Görs 29cd012627 core: update German translations 2019-09-18 13:51:46 +02:00
Sébastien Helleu d26893a70d core: update ChangeLog (closes #1400) 2019-09-17 21:29:28 +02:00
Tobias Stoeckmann f7b84fcc67 Fixed segfault during excessive evaluation.
It is possible to trigger a segmentation fault while processing
an evaluation of repeating string. On a Linux 64 bit system,
enter this (or adjust arguments for 32 bit accordingly):

/eval -n ${repeat:1073741824,----}

It will overflow an integer calculation because int instead of
size_t is used. Proper check of int limitations fixes this issue.

I haven't changed this specific piece of code to size_t because it
would crash in other parts of the code tree instead. For now, int
is a limitating factor when it comes to strings (and should be
enough for sane use cases).

Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
2019-09-17 21:26:52 +02:00
Sébastien Helleu 63a05d72d9 buflist: fix extra spaces between buffers when conditions are used to hide buffers (closes #1403)
This is a regression introduced in version 2.6 by commit
bf21ca072d.
2019-09-17 21:21:28 +02:00
Sébastien Helleu 40eb257d0d doc: update German auto-generated file 2019-09-17 09:02:45 +02:00
Nils Görs 8e267ad9f3 core: update German translations 2019-09-17 08:41:54 +02:00
Sébastien Helleu e8be4f62af core: mention possible background color in /help weechat.look.nick_color_force 2019-09-16 20:58:12 +02:00
Sébastien Helleu ea0bdbab1b debian: fix build of packages on Debian Jessie (issue #916, issue #956)
With the new errors on missing libraries in CMake, the PHP plugin must be
explicitly disabled.
2019-09-16 08:46:00 +02:00
Sébastien Helleu d690544499 core: update ChangeLog 2019-09-15 14:53:02 +02:00
Sébastien Helleu ab768ce902 core: remove obsolete file FindTCL.cmake (issue #916, issue #956)
This is file is provided by CMake and is not needed any more.  Moreover, it
causes an error on FreeBSD (TCL not found), even if TCL was properly detected
and used during the build.
2019-09-15 14:48:52 +02:00
Sébastien Helleu bff40e4c26 core: display an error on missing dependency in CMake (closes #916, closes #956) 2019-09-15 07:49:03 +02:00
Sébastien Helleu 9cb6857672 Version 2.7-dev 2019-09-08 08:33:06 +02:00
Simmo Saan 49ce989de6 gui: fix separator overlap check for deeply nested windows 2015-12-22 10:39:58 +02:00
Simmo Saan 9cc68b641b gui: fix window separators not respecting window splits 2015-12-21 17:41:38 +02:00
Simmo Saan 93d2dbf3e1 gui: add missing line pointer to long words split across lines (closes #617)
Displaying a word which was forced to be split across lines added the new
coords without pointer to the original line. This made them unquotable in
cursor mode.
2015-12-03 12:00:22 +02:00
Simmo Saan bcb7ac7777 gui: fix focus data being offset when prefix_align is none (closes #610)
window->coords_x_message stored a single x coordinate for the entire
window which was used for message position calculation. Such approach
does not work when prefix_align is none, thus now the x coordinate in
question is exactly calculated for a line individually.
2015-12-03 11:57:09 +02:00
733 changed files with 22026 additions and 7483 deletions
+1
View File
@@ -1,6 +1,7 @@
---
name: Bug report
about: Create a bug report (please do not report security issues here)
labels: bug
---
@@ -1,6 +1,7 @@
---
name: Feature request
about: Request a new feature / enhancement
labels: feature
---
+1
View File
@@ -1,6 +1,7 @@
---
name: Question
about: Ask a question (please read first FAQ and docs)
labels: question
---
+2 -1
View File
@@ -16,7 +16,8 @@
ABOUT-NLS
autom4te*
build*/*
build/*
builddir/*
compile
config.guess
config.h
+2
View File
@@ -68,6 +68,7 @@ Alphabetically:
* Koka El Kiwi (KiwiDash)
* Krzysztof Koroscik (soltys)
* Kyle Fuller (kylef)
* Kyle Sabo
* Leonid Evdokimov
* Lázaro A.
* Linus Heckemann
@@ -76,6 +77,7 @@ Alphabetically:
* Marco Paolone
* Mateusz Poszwa
* Matt Robinson
* Matthew Horan
* Matthew Martin
* Max Anton Teufel
* Maxim Baz
+33 -13
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2007-2008 Julien Louis <ptitlouis@sysif.net>
# Copyright (C) 2008-2009 Emmanuel Bouthenot <kolter@openics.org>
#
@@ -180,6 +180,12 @@ if(ENABLE_NLS)
find_package(Gettext)
if(GETTEXT_FOUND)
add_definitions(-DENABLE_NLS)
find_package(Intl)
if(Intl_FOUND)
list(APPEND EXTRA_LIBS "${Intl_LIBRARIES}")
endif()
else()
message(SEND_ERROR "Gettext not found")
endif()
endif()
@@ -197,6 +203,8 @@ if(ENABLE_GNUTLS)
include_directories(${GNUTLS_INCLUDE_PATH})
set(CMAKE_C_LINK_FLAGS "${CMAKE_C_LINK_FLAGS} -L${GNUTLS_LIBRARY_PATH}")
list(APPEND EXTRA_LIBS gnutls)
else()
message(SEND_ERROR "GnuTLS not found")
endif()
endif()
@@ -227,6 +235,8 @@ if(DL_LIBRARY)
list(APPEND EXTRA_LIBS dl)
endif()
add_subdirectory(icons)
if(ENABLE_NLS)
add_subdirectory(po)
endif()
@@ -234,10 +244,14 @@ endif()
add_subdirectory(src)
add_subdirectory(doc)
find_package(CppUTest)
if(ENABLE_TESTS AND CPPUTEST_FOUND)
enable_testing()
add_subdirectory(tests)
if(ENABLE_TESTS)
find_package(CppUTest)
if(CPPUTEST_FOUND)
enable_testing()
add_subdirectory(tests)
else()
message(SEND_ERROR "CppUTest not found")
endif()
endif()
configure_file(config.h.cmake config.h @ONLY)
@@ -245,19 +259,23 @@ configure_file(config.h.cmake config.h @ONLY)
# set the git version in "config-git.h"
add_custom_target(version_git ALL
COMMAND "${CMAKE_CURRENT_SOURCE_DIR}/tools/git-version.sh" "${CMAKE_CURRENT_SOURCE_DIR}" "${VERSION}" "config-git.h"
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}")
WORKING_DIRECTORY "${CMAKE_CURRENT_BINARY_DIR}"
)
configure_file(
"${CMAKE_CURRENT_SOURCE_DIR}/cmake/cmake_uninstall.cmake.in"
"${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
IMMEDIATE @ONLY)
IMMEDIATE @ONLY
)
add_custom_target(uninstall
"${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake")
"${CMAKE_COMMAND}" -P "${CMAKE_CURRENT_BINARY_DIR}/cmake_uninstall.cmake"
)
add_custom_target(dist
"${CMAKE_CURRENT_SOURCE_DIR}/tools/makedist.sh" "${VERSION}" "HEAD" "${CMAKE_CURRENT_BINARY_DIR}"
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR})
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
)
# pkgconfig file
set(PACKAGE "${PROJECT_NAME}")
@@ -279,11 +297,12 @@ if(CYGWIN)
${CMAKE_CURRENT_SOURCE_DIR}/Contributing.adoc
${CMAKE_CURRENT_SOURCE_DIR}/README.adoc
${CMAKE_CURRENT_SOURCE_DIR}/ReleaseNotes.adoc
DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME})
DESTINATION ${SHAREDIR}/doc/${PROJECT_NAME}
)
endif()
# icon
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/weechat.png DESTINATION ${SHAREDIR}/icons/hicolor/32x32/apps)
# desktop file
install(FILES ${CMAKE_CURRENT_SOURCE_DIR}/weechat.desktop DESTINATION ${SHAREDIR}/applications)
# packages
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "Fast, light and extensible chat client")
@@ -301,7 +320,8 @@ set(CPACK_PACKAGE_FILE_NAME weechat-binary-${VERSION})
# source package
set(CPACK_SOURCE_GENERATOR "TGZ;TBZ2")
set(CPACK_SOURCE_PACKAGE_FILE_NAME weechat-${VERSION})
set(CPACK_SOURCE_IGNORE_FILES "/\\\\.git" "/build/" "/m4/"
set(CPACK_SOURCE_IGNORE_FILES
"/\\\\.git" "/build/" "/m4/"
"/autom4te\\\\.cache/" "/ABOUT-NLS$" "/config\\\\.guess$" "/config\\\\.h$"
"/config\\\\.h.in$" "/config\\\\.log$" "/config\\\\.rpath$"
"/config\\\\.status$" "/config\\\\.sub$" "/configure$" "/depcomp$"
+123 -10
View File
@@ -15,6 +15,119 @@ https://weechat.org/files/releasenotes/ReleaseNotes-devel.html[release notes]
(file _ReleaseNotes.adoc_ in sources).
[[v2.8]]
== Version 2.8 (2020-03-29)
New features::
* core: add variable "old_full_name" in buffer, set during buffer renaming (issue #1428)
* core: add debug option "-d" in command /eval (issue #1434)
* api: add functions crypto_hash and crypto_hash_pbkdf2
* api: add info "auto_connect" (issue #1453)
* api: add info "weechat_headless" (issue #1433)
* buflist: add pointer "window" in bar item evaluation
* irc: add support of fake servers (no I/O, for testing purposes)
* relay: accept hash of password in init command of weechat protocol with option "password_hash" (PBKDF2, SHA256, SHA512)
* relay: reject client with weechat protocol if password or totp is received in init command but not set in WeeChat (issue #1435)
Bug fixes::
* core: fix memory leak in completion
* core: flush stdout/stderr before forking in hook_process function (issue #1441)
* core: fix evaluation of condition with nested "if" (issue #1434)
* irc: split AUTHENTICATE message in 400-byte chunks (issue #1459)
* irc: copy temporary server flag in command /server copy
* irc: add nick changes in the hotlist (except self nick change)
* irc: case-insensitive comparison on incoming CTCP command, force upper case on CTCP replies (issue #1439)
* irc: fix memory leak when the channel topic is changed
* logger: fix crash when logging is disabled on a buffer and the log file was deleted in the meanwhile, when option logger.file.info_lines is on (issue #1444)
* php: fix crash when loading script with PHP 7.4 (issue #1452)
* relay: update buffers synchronization when buffers are renamed (issue #1428)
* script: fix memory leak in read of script repository file if it has invalid content
* script: fix unexpected display of scripts list in buffer with command /script list -i
* xfer: send signal "xfer_ended" after the received file has been renamed (issue #1438)
Tests::
* scripts: fix generation of test scripts with Python 3.8
* unit: add tests on IRC protocol functions and callbacks
* unit: add tests on function secure_derive_key
* unit: add tests on functions util_get_time_diff and util_file_get_content
Build::
* core: fix Cygwin build
* guile: add detection of Guile 3.0.0 (issue #1442)
* irc: fix build with GnuTLS < 3.1.0 (issue #1431)
* php: add detection of PHP 7.4
* ruby: add detection of Ruby 2.7 (issue #1455)
[[v2.7.1]]
== Version 2.7.1 (2020-02-20)
Bug fixes::
* irc: fix crash when a new message 005 is received with longer nick prefixes (CVE-2020-9760)
* irc: fix crash when receiving a malformed message 352 (who) (CVE-2020-9759)
* irc: fix crash when receiving a malformed message 324 (channel mode) (CVE-2020-8955)
[[v2.7]]
== Version 2.7 (2019-12-08)
New features::
* core: add option weechat.look.nick_color_hash_salt to shuffle nick colors (issue #635)
* core: add different icons sizes (16x16 to 512x512) (issue #1347)
* core: add file weechat.desktop
* core: add reverse of string for screen in evaluation of expressions with "revscr:"
* core: add length of string (number of chars and on screen) in evaluation of expressions with "length:xxx" and "lengthscr:xxx"
* core: add calculation of expression in evaluation of expressions with "calc:xxx" (issue #997)
* core: add optional default path (evaluated) in completion "filename"
* core: add support of modifiers in evaluation of expressions with "modifier:name,data,string"
* api: add modifier "color_encode_ansi" (issue #528)
* api: add modifier "eval_path_home"
* irc: add filters on raw buffer (issue #1000)
* irc: add option irc.look.display_pv_warning_address to display a warning in private buffer if the remote nick address has changed (issue #892)
* irc: add server option "ssl_password" (issue #115, issue #1416)
* irc: add "user" in output of irc_message_parse (issue #136)
* irc: add options irc.color.message_kick and irc.color.reason_kick (issue #683, issue #684)
* logger: add option logger.file.color_lines (issue #528, issue #621)
* script: add options "-ol" and "-il" in command "/script list" to send translated string with list of scripts loaded, display "No scripts loaded" if no scripts are loaded
* xfer: add option xfer.file.download_temporary_suffix with default value ".part" (issue #1237)
Bug fixes::
* core: set buffer name, short name and title only if the value has changed
* core: fix scrolling up in bare mode when switched to bare mode at the top of the buffer (issue #899, issue #978)
* core: optimize load of configuration files
* core: fix window separators not respecting window splits (issue #630)
* core: fix cursor mode info when prefix_align is none and with words split across lines (issue #610, issue #617, issue #619)
* core: add support of reverse video in ANSI color codes
* core: fixed segfault during excessive evaluation in function string_repeat (issue #1400)
* buflist: fix extra spaces between buffers when conditions are used to hide buffers (regression introduced in version 2.6) (issue #1403)
* irc: do not automatically open a channel with name "0" (issue #1429)
* irc: remove option irc.network.channel_encode, add server option "charset_message" to control which part of the IRC message is decoded/encoded to the target charset (issue #832)
* irc: use path from option xfer.file.upload_path to complete filename in command "/dcc send" (issue #60)
* logger: fix write in log file if it has been deleted or renamed (issue #123)
* python: send "bytes" instead of "str" to callbacks in Python 3 when the string is not UTF-8 valid (issue #1389)
* relay: send message "_buffer_title_changed" to clients only when the title is changed
* xfer: fix memory leak when a xfer is freed and when the plugin is unloaded
Tests::
* unit: add tests on GUI color functions
Build::
* core: fix build on Haiku (issue #1420)
* core: fix build on Alpine
* core: remove file FindTCL.cmake
* core: display an error on missing dependency in CMake (issue #916, issue #956)
* debian: disable Javascript plugin on Debian Sid and Ubuntu Eoan
* debian: build with Guile 2.2
* guile: add support of Guile 2.2, disable /guile eval (issue #1098)
* python: add detection of Python 3.8
[[v2.6]]
== Version 2.6 (2019-09-08)
@@ -165,11 +278,11 @@ New features::
* core: add repeat of string in evaluation of expressions with "repeat:count,string" (issue #958)
* core: allow specifying buffer number/name for /buffer localvar (issue #1259)
* core: allow multiple arguments in command /buffer close
* core: allow multiple arguments in command "/buffer close"
* core: allow multiple options "-r" (or "--run-command") in command line arguments (issue #1248)
* core: add command line option "-P" (or "--plugins") to customize the plugins to load at startup
* core: allow partial buffer name in command /buffer close (issue #1226)
* api: add function hook_line
* core: allow partial buffer name in command "/buffer close" (issue #1226)
* api: add function hook_line (issue #66)
* irc: display a warning when the value of option irc.server.xxx.autojoin is set to an invalid value
* relay: add real IP in client description (issue #1256)
* trigger: allow creation of temporary variables with the regex
@@ -310,7 +423,7 @@ New features::
* core: add flag "input_get_empty" in buffer
* core: add signals "buffer_filters_enabled" and "buffer_filters_disabled"
* core: support loading of plugins from path in environment variable "WEECHAT_EXTRA_LIBDIR" (issue #971, issue #979)
* core: make value optional in command /buffer set (issue #746, issue #1088)
* core: make value optional in command "/buffer set" (issue #746, issue #1088)
* core: allow floating point and hexadecimal numbers in comparison of evaluated values
* core: add option weechat.look.save_config_with_fsync (issue #1083)
* api: add support of prefix "quiet:" in function key_unbind to quietly remove keys
@@ -395,7 +508,7 @@ Bug fixes::
New features::
* core: add option weechat.completion.nick_case_sensitive (issue #981)
* core: add wilcard matching operator (`+=*+` and `+!*+`) in evaluation of expressions (issue #611)
* core: add wildcard matching operator (`+=*+` and `+!*+`) in evaluation of expressions (issue #611)
* core: add cut of string in evaluation of expressions with "cut:" (number of chars) and "cutscr:" (number of chars displayed on screen)
* core: add ternary operator (condition) in evaluation of expressions (`${if:condition?value_if_true:value_if_false}`)
* core: add resize of window parents with /window resize [h/v]size (task #11461, issue #893)
@@ -488,7 +601,7 @@ Build::
New features::
* core: add optional argument "lowest", "highest" or level mask in command /input hotlist_clear
* core: add optional argument "lowest", "highest" or level mask in command "/input hotlist_clear"
* core: add option "cycle" in command /buffer
* core, irc, xfer: display more information on memory allocation errors (issue #573)
* api: add "extra" argument to evaluate extra variables in function string_eval_expression (issue #534)
@@ -685,7 +798,7 @@ New features::
* core: add options weechat.look.word_chars_{highlight|input} (issue #55, task #9459)
* core: remove WeeChat version from config files (issue #407)
* core: display a warning on startup if the locale can not be set (issue #373)
* core: allow "*" as plugin name in command /plugin reload to reload all plugins with options
* core: allow "*" as plugin name in command "/plugin reload" to reload all plugins with options
* core: add option "-s" in command /eval to split expression before evaluating it (no more split by default) (issue #324)
* core: add priority in plugins to initialize them in order
* api: add support of environment variables in function string_eval_expression and command /eval
@@ -1629,14 +1742,14 @@ New features::
* core: allow name of buffer for command /buffer clear (task #11269)
* core: add new command /repeat (execute a command several times)
* core: save and restore layout for buffers and windows on /upgrade
* core: add option "-all" in command /buffer unmerge
* core: add option "-all" in command "/buffer unmerge"
* core: add number in windows (add optional argument "-window" so some actions for command /window)
* core: allow buffer name in /buffer close
* core: add support of mouse: new command /mouse, new key context "mouse", new options weechat.look.mouse and weechat.look.mouse_timer_delay (task #5435)
* core: add command /cursor (free movement of cursor on screen), with key context "cursor"
* core: automatic scroll direction in /bar scroll (x/y is now optional)
* core: add optional delay for key grab (commands /input grab_key and /input grab_key_command, default is 500 milliseconds)
* core: allow plugin name in command /buffer name
* core: allow plugin name in command "/buffer name"
* core: add context "search" for keys (to define keys used during search in buffer with kbd:[Ctrl+r])
* core: add new option weechat.look.separator_vertical, rename option weechat.look.hline_char to weechat.look.separator_horizontal
* core: add local variable "highlight_regex" in buffers
@@ -1717,7 +1830,7 @@ New features::
* core: add option weechat.look.hotlist_buffer_separator
* core: add messages counts in hotlist for each buffer, new options: weechat.look.hotlist_count_max, weechat.look.hotlist_count_min_msg and weechat.color.status_count_{msg|private|highlight|other}
* core: add tag "notify_none" (line with this tag will not update hotlist)
* core: add optional bar name in command /bar default
* core: add optional bar name in command "/bar default"
* core: add new option weechat.look.highlight_tags (force highlight on tags)
* core: allow list of buffers in command /filter (exclusion with prefix "!") (task #10880)
* core: allow relative size for command /window resize
+6 -7
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2005 Julien Louis <ptitlouis@sysif.net>
# Copyright (C) 2006-2009 Emmanuel Bouthenot <kolter@openics.org>
#
@@ -29,7 +29,7 @@ if TESTS
tests_dir = tests
endif
SUBDIRS = po doc intl src $(tests_dir)
SUBDIRS = icons po doc intl src $(tests_dir)
EXTRA_DIST = AUTHORS.adoc \
ChangeLog.adoc \
@@ -56,7 +56,6 @@ EXTRA_DIST = AUTHORS.adoc \
cmake/FindPkgConfig.cmake \
cmake/FindPython.cmake \
cmake/FindRuby.cmake \
cmake/FindTCL.cmake \
cmake/FindV8.cmake \
cmake/FindZLIB.cmake \
cmake/cmake_uninstall.cmake.in \
@@ -66,17 +65,17 @@ EXTRA_DIST = AUTHORS.adoc \
tools/git-version.sh \
tools/makedist.sh \
version.sh \
weechat.png \
weechat.desktop \
weechat.pc.in \
weechat.cygport.in
ACLOCAL_AMFLAGS = -I m4
pkgconfigdir = $(libdir)/pkgconfig
pkgconfigdir = $(libdir)/pkgconfig
pkgconfig_DATA = weechat.pc
icondir = $(datadir)/icons/hicolor/32x32/apps
icon_DATA = weechat.png
desktopdir = $(datadir)/applications
desktop_DATA = weechat.desktop
clean-local:
$(RM) config-git.h
+2 -2
View File
@@ -8,7 +8,7 @@ pass:[<p align="center">] image:https://weechat.org/media/images/weechat_logo_la
image:https://img.shields.io/badge/diaspora*-follow-blue.svg["Diaspora*", link="https://diasp.eu/u/weechat"]
image:https://img.shields.io/badge/mastodon-follow-blue.svg["Mastodon", link="https://hostux.social/@weechat"]
image:https://img.shields.io/badge/twitter-follow-blue.svg["Twitter", link="https://twitter.com/WeeChatClient"]
image:https://img.shields.io/badge/devel%20blog-follow-blue.svg["Devel blog", link="https://weechat.org/blog/"]
image:https://img.shields.io/badge/devel%20blog-follow-blue.svg["Devel blog", link="https://blog.weechat.org/"]
image:https://img.shields.io/badge/slant-recommend-28acad.svg["Slant", link="https://www.slant.co/topics/1323/~best-irc-clients-for-linux"]
image:https://img.shields.io/badge/help-donate%20%E2%9D%A4-ff69b4.svg["Donate", link="https://weechat.org/donate/"]
@@ -114,7 +114,7 @@ $ ctest -V
== Copyright
Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
This file is part of WeeChat, the extensible chat client.
+134
View File
@@ -17,6 +17,140 @@ https://weechat.org/files/changelog/ChangeLog-devel.html[ChangeLog]
(file _ChangeLog.adoc_ in sources).
[[v2.8]]
== Version 2.8 (2020-03-29)
[[v2.8_auto_connection_to_servers]]
=== Auto connection to servers
The command line option `-a` (or `--no-connect`), which can also be used in the
`/plugin` command, is now used to set a new info called `auto_connect`
(see the function "info_get" in the Plugin API reference).
Therefore, the option is not sent any more to the function `weechat_plugin_init`
of plugins. +
The plugins using this option must now get the info `auto_connect` and check
if the value is "1" (a string with just `1`).
The purpose of this change is to allow scripts as well to check this info on
startup, and connect or not, depending on the value (see issue #1453).
To be compatible with WeeChat ≤ 2.7, the script can do this, for example
in Python:
[source,python]
----
auto_connect = weechat.info_get("auto_connect", "") != "0"
----
The variable `auto_connect` will be set like that, depending on the WeeChat
version:
* WeeChat ≤ 2.7: always `True` because the info is an empty string (it does not
exist), which is different from "0",
* WeeChat ≥ 2.8: `True` by default, and `False` if `-a` or `--no-connect` is
given by the user (either on command line or when loading the plugin).
[[v2.7.1]]
== Version 2.7.1 (2020-02-20)
Bug fix and maintenance release.
[[v2.7]]
== Version 2.7 (2019-12-08)
[[v2.7_cmake_errors]]
=== CMake errors on missing dependencies
When compiling WeeChat with CMake (which is the recommended way), errors are
now displayed on any missing dependency, if the optional feature was enabled
(most features are automatically enabled, except documentation, man page and
tests).
Any error on a missing dependency is fatal, so WeeChat can not be compiled.
This is a new behavior compared to old versions, where any missing dependency
was silently ignored and the compilation was possible anyway.
For example if PHP is not installed on your system, CMake will display an error
on missing PHP library:
----
-- checking for one of the modules 'php7'
CMake Warning at cmake/FindPHP.cmake:57 (message):
Could not find libphp7. Ensure PHP >=7.0.0 development libraries are
installed and compiled with `--enable-embed`. Ensure `php-config` is in
`PATH`. You may set `-DCMAKE_LIBRARY_PATH=...` to the directory containing
libphp7.
Call Stack (most recent call first):
src/plugins/CMakeLists.txt:157 (find_package)
CMake Error at src/plugins/CMakeLists.txt:161 (message):
Php not found
----
Then you can either install PHP or explicitly disable PHP if you don't need this
plugin, using this cmake option:
----
cmake .. -DENABLE_PHP=OFF
----
[[v2.7_python3_callbacks_strings]]
=== Strings received in Python 3 callbacks
The strings sent to script callbacks in Python 3 are now automatically converted
according to the content:
* if the string is valid UTF-8, it is sent as `str` (legacy behavior)
* if the string is not valid UTF-8, it is sent as `bytes` (new).
In some cases only, the string may not be valid UTF-8, so it is received as
`bytes` in the callback, which must take care of that.
For more information, see the WeeChat scripting guide: chapter about strings
received in callbacks (see also issue #1389).
Note: there are no changes for Python 2 (which is now deprecated and should not
be used any more), the strings sent to callbacks are always of type `str`, and
may contain invalid UTF-8 data, in the cases mentioned in the WeeChat scripting
guide.
[[v2.7_irc_message_decoding]]
=== IRC message decoding/encoding
A new server option called "charset_message" has been added, replacing the
option _irc.network.channel_encode_.
This new server option has three possible values:
* _message_ (default): the whole IRC message is decoded/encoded, this is the
new default behavior; in case of problem with channel names, try to use
_text_ instead
* _channel_: the message is decoded/encoded starting at the channel name (or
the text if no channel is present); this is like setting the old option
_irc.network.channel_encode_ to _on_
* _text_: the message is decoded/encoded starting from the text (for example
the user message); this is like setting the old option
_irc.network.channel_encode_ to _off_ (so this was the default behavior
in previous versions)
[[v2.7_xfer_file_receive_suffix]]
=== Suffix for files received via DCC
Files received via DCC (xfer plugin) now have a suffix ".part" during the
transfer. When the transfer is successful, the suffix is removed.
This suffix can be customized with the new option
_xfer.file.download_temporary_suffix_.
If you prefer the legacy behavior (no suffix added), you can set an empty value
in the new option:
----
/set xfer.file.download_temporary_suffix ""
----
[[v2.6]]
== Version 2.6 (2019-09-08)
+5 -6
View File
@@ -1,6 +1,6 @@
#!/bin/sh
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2005 Julien Louis <ptitlouis@sysif.net>
# Copyright (C) 2005-2006 Emmanuel Bouthenot <kolter@openics.org>
#
@@ -24,8 +24,8 @@
### common stuff
###
DIR=$(cd $(dirname "$0"); pwd)
cd $DIR
DIR=$(cd "$(dirname "$0")" || exit 1; pwd)
cd "$DIR" || exit 1
AUTOGEN_LOG=autogen.log
@@ -41,9 +41,8 @@ err ()
run ()
{
echo -n "Running \"$@\"..."
eval $@ >$AUTOGEN_LOG 2>&1
if [ $? = 0 ] ; then
printf "Running \"%s\"..." "$@"
if eval "$@" >$AUTOGEN_LOG 2>&1 ; then
echo " OK"
else
echo " FAILED"
+3 -3
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -34,7 +34,7 @@ if(ASCIIDOCTOR_EXECUTABLE)
execute_process(
COMMAND ${ASCIIDOCTOR_EXECUTABLE} --version
OUTPUT_VARIABLE ASCIIDOCTOR_VERSION
)
)
string(REGEX REPLACE "^Asciidoctor ([^ ]+) .*" "\\1" ASCIIDOCTOR_VERSION "${ASCIIDOCTOR_VERSION}")
@@ -45,5 +45,5 @@ if(ASCIIDOCTOR_EXECUTABLE)
mark_as_advanced(
ASCIIDOCTOR_EXECUTABLE
ASCIIDOCTOR_VERSION
)
)
endif()
+2 -2
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -55,4 +55,4 @@ endif()
mark_as_advanced(
ASPELL_INCLUDE_PATH
ASPELL_LIBRARY
)
)
+3 -3
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2014-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2014-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -27,8 +27,8 @@
# CPPUTEST_LIBRARIES = Link options to compile with CppUTest
if(CPPUTEST_FOUND)
# Already in cache, be silent
set(CPPUTEST_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(CPPUTEST_FIND_QUIETLY TRUE)
endif()
find_package(PkgConfig)
+10 -11
View File
@@ -13,10 +13,8 @@
if(ENCHANT_INCLUDE_DIR AND ENCHANT_LIBRARIES)
# in cache already
set(ENCHANT_FOUND TRUE)
else()
if(NOT WIN32)
# use pkg-config to get the directories and then use these values
@@ -27,17 +25,19 @@ else()
endif()
find_path(ENCHANT_INCLUDE_DIR
NAMES enchant++.h
HINTS ${PC_ENCHANT_INCLUDEDIR}
${PC_ENCHANT_INCLUDE_DIRS}
PATH_SUFFIXES enchant )
NAMES enchant++.h
HINTS ${PC_ENCHANT_INCLUDEDIR} ${PC_ENCHANT_INCLUDE_DIRS}
PATH_SUFFIXES enchant
)
find_library(ENCHANT_LIBRARIES NAMES enchant
HINTS ${PC_ENCHANT_LIBDIR}
${PC_ENCHANT_LIBRARY_DIRS} )
find_library(ENCHANT_LIBRARIES
NAMES enchant
HINTS ${PC_ENCHANT_LIBDIR}
${PC_ENCHANT_LIBRARY_DIRS}
)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(ENCHANT DEFAULT_MSG ENCHANT_INCLUDE_DIR ENCHANT_LIBRARIES )
find_package_handle_standard_args(ENCHANT DEFAULT_MSG ENCHANT_INCLUDE_DIR ENCHANT_LIBRARIES)
mark_as_advanced(ENCHANT_INCLUDE_DIR ENCHANT_LIBRARIES)
@@ -47,5 +47,4 @@ else()
check_symbol_exists(enchant_get_version "enchant.h" HAVE_ENCHANT_GET_VERSION)
set(CMAKE_REQUIRED_INCLUDES)
set(CMAKE_REQUIRED_LIBRARIES)
endif()
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+4 -5
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2007 Julien Louis <ptitlouis@sysif.net>
# Copyright (C) 2009 Emmanuel Bouthenot <kolter@openics.org>
#
@@ -28,8 +28,8 @@
# GETTEXT_FOUND = is gettext usable on system?
if(GETTEXT_FOUND)
# Already in cache, be silent
set(GETTEXT_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(GETTEXT_FIND_QUIETLY TRUE)
endif()
include(CheckIncludeFiles)
@@ -54,7 +54,7 @@ if(HAVE_LIBINTL_H)
PATHS
/usr/local/lib
/usr/lib
)
)
if(LIBINTL_LIBRARY)
if(${CMAKE_SYSTEM_NAME} STREQUAL "OpenBSD")
set(CMAKE_REQUIRED_LIBRARIES "iconv")
@@ -62,7 +62,6 @@ if(HAVE_LIBINTL_H)
else()
check_library_exists(${LIBINTL_LIBRARY} "dgettext" "" LIBINTL_HAS_DGETTEXT)
endif()
if(LIBINTL_HAS_DGETTEXT)
set(GETTEXT_FOUND TRUE)
endif()
+6 -6
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2009 Emmanuel Bouthenot <kolter@openics.org>
#
# This file is part of WeeChat, the extensible chat client.
@@ -30,23 +30,23 @@
# GNUTLS_LDFLAGS = ldflags to use to compile
if(GNUTLS_INCLUDE_PATH AND GNUTLS_LIBRARY)
# Already in cache, be silent
set(GNUTLS_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(GNUTLS_FIND_QUIETLY TRUE)
endif()
find_program(PKG_CONFIG_EXECUTABLE NAMES pkg-config)
execute_process(COMMAND ${PKG_CONFIG_EXECUTABLE} --variable=prefix gnutls
OUTPUT_VARIABLE GNUTLS_PREFIX
OUTPUT_VARIABLE GNUTLS_PREFIX
)
execute_process(COMMAND ${PKG_CONFIG_EXECUTABLE} --cflags gnutls
OUTPUT_VARIABLE GNUTLS_CFLAGS
OUTPUT_VARIABLE GNUTLS_CFLAGS
)
string(REGEX REPLACE "[\r\n]" "" GNUTLS_CFLAGS "${GNUTLS_CFLAGS}")
execute_process(COMMAND ${PKG_CONFIG_EXECUTABLE} --libs gnutls
OUTPUT_VARIABLE GNUTLS_LDFLAGS
OUTPUT_VARIABLE GNUTLS_LDFLAGS
)
string(REGEX REPLACE "[\r\n]" "" GNUTLS_LDFLAGS "${GNUTLS_LDFLAGS}")
+4 -4
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2011-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2011-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -27,13 +27,13 @@
# GUILE_LIBRARIES = Link options to compile Guile
if(GUILE_FOUND)
# Already in cache, be silent
set(GUILE_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(GUILE_FIND_QUIETLY TRUE)
endif()
find_package(PkgConfig)
if(PKG_CONFIG_FOUND)
pkg_search_module(GUILE guile-2.0)
pkg_search_module(GUILE guile-3.0 guile-2.2 guile-2.0)
if(GUILE_FOUND)
# check if variable "scm_install_gmp_memory_functions" exists
set(CMAKE_REQUIRED_INCLUDES ${GUILE_INCLUDE_DIRS})
+3 -3
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -29,8 +29,8 @@
# ICONV_FOUND = is iconv usable on system?
if(ICONV_FOUND)
# Already in cache, be silent
set(ICONV_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(ICONV_FIND_QUIETLY TRUE)
endif()
include(CheckLibraryExists)
+3 -3
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -29,8 +29,8 @@
# LUA_FOUND = is liblua usable on system?
if(LUA_FOUND)
# Already in cache, be silent
set(LUA_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(LUA_FIND_QUIETLY TRUE)
endif()
find_package(PkgConfig)
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+8 -4
View File
@@ -1,5 +1,6 @@
#
# Copyright (C) 2003-2017 Adam Saponara <as@php.net>
# Copyright (C) 2017 Adam Saponara <as@php.net>
# Copyright (C) 2017-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -28,11 +29,13 @@ endif()
if(NOT PHP_FOUND)
find_program(PHP_CONFIG_EXECUTABLE NAMES
php-config7.4 php-config74
php-config7.3 php-config73
php-config7.2 php-config72
php-config7.1 php-config71
php-config7.0 php-config70
php-config php-config7)
php-config php-config7
)
if (PHP_CONFIG_EXECUTABLE)
execute_process(COMMAND ${PHP_CONFIG_EXECUTABLE} --prefix OUTPUT_VARIABLE PHP_LIB_PREFIX OUTPUT_STRIP_TRAILING_WHITESPACE)
execute_process(COMMAND ${PHP_CONFIG_EXECUTABLE} --includes OUTPUT_VARIABLE PHP_INCLUDE_DIRS OUTPUT_STRIP_TRAILING_WHITESPACE)
@@ -40,8 +43,9 @@ if(NOT PHP_FOUND)
execute_process(COMMAND ${PHP_CONFIG_EXECUTABLE} --version OUTPUT_VARIABLE PHP_VERSION OUTPUT_STRIP_TRAILING_WHITESPACE)
if(${PHP_VERSION} MATCHES "^7")
find_library(PHP_LIB
NAMES php7.3 php7.2 php7.1 php7.0 php7
HINTS ${PHP_LIB_PREFIX} ${PHP_LIB_PREFIX}/lib ${PHP_LIB_PREFIX}/lib64)
NAMES php7.4 php7.3 php7.2 php7.1 php7.0 php7
HINTS ${PHP_LIB_PREFIX} ${PHP_LIB_PREFIX}/lib ${PHP_LIB_PREFIX}/lib64
)
if(PHP_LIB)
get_filename_component(PHP_LIB_DIR ${PHP_LIB} DIRECTORY)
string(REPLACE "-I" "" PHP_INCLUDE_DIRS ${PHP_INCLUDE_DIRS})
+10 -10
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -29,31 +29,31 @@
# PERL_LFLAGS = perl compiler options for linking
if(PERL_FOUND)
# Already in cache, be silent
set(PERL_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(PERL_FIND_QUIETLY TRUE)
endif()
find_program(PERL_EXECUTABLE
NAMES perl perl5
PATHS /usr/bin /usr/local/bin /usr/pkg/bin
)
)
if(PERL_EXECUTABLE)
execute_process(
COMMAND ${PERL_EXECUTABLE} -MConfig -e "print \"\$Config{archlibexp}/CORE\""
OUTPUT_VARIABLE PERL_INTERNAL_DIR
)
)
execute_process(
COMMAND ${PERL_EXECUTABLE} -MExtUtils::Embed -e ccopts
OUTPUT_VARIABLE PERL_CFLAGS
)
)
execute_process(
COMMAND ${PERL_EXECUTABLE} -MExtUtils::Embed -e ldopts
OUTPUT_VARIABLE PERL_LFLAGS
)
)
# remove the new lines from the output by replacing them with empty strings
string(REPLACE "\n" "" PERL_INTERNAL_DIR "${PERL_INTERNAL_DIR}")
@@ -63,12 +63,12 @@ if(PERL_EXECUTABLE)
find_path(PERL_INCLUDE_PATH
NAMES perl.h
PATHS ${PERL_INTERNAL_DIR}
)
)
find_library(PERL_LIBRARY
NAMES perl
PATHS /usr/lib /usr/local/lib /usr/pkg/lib ${PERL_INTERNAL_DIR}
)
)
if(PERL_LIBRARY AND PERL_INCLUDE_PATH)
set(PERL_FOUND TRUE)
@@ -80,5 +80,5 @@ if(PERL_EXECUTABLE)
PERL_LIBRARY
PERL_CFLAGS
PERL_LFLAGS
)
)
endif()
+597 -185
View File
@@ -1,117 +1,60 @@
# - a pkg-config module for CMake
#
# Usage:
# pkg_check_modules(<PREFIX> [REQUIRED] <MODULE> [<MODULE>]*)
# checks for all the given modules
#
# pkg_search_module(<PREFIX> [REQUIRED] <MODULE> [<MODULE>]*)
# checks for given modules and uses the first working one
#
# When the 'REQUIRED' argument was set, macros will fail with an error
# when module(s) could not be found
#
# It sets the following variables:
# PKG_CONFIG_FOUND ... true iff pkg-config works on the system
# PKG_CONFIG_EXECUTABLE ... pathname of the pkg-config program
# <PREFIX>_FOUND ... set to 1 iff module(s) exist
#
# For the following variables two sets of values exist; first one is the
# common one and has the given PREFIX. The second set contains flags
# which are given out when pkgconfig was called with the '--static'
# option.
# <XPREFIX>_LIBRARIES ... only the libraries (w/o the '-l')
# <XPREFIX>_LIBRARY_DIRS ... the paths of the libraries (w/o the '-L')
# <XPREFIX>_LDFLAGS ... all required linker flags
# <XPREFIX>_LDFLAGS_OTHER ... all other linker flags
# <XPREFIX>_INCLUDE_DIRS ... the '-I' preprocessor flags (w/o the '-I')
# <XPREFIX>_CFLAGS ... all required cflags
# <XPREFIX>_CFLAGS_OTHER ... the other compiler flags
#
# <XPREFIX> = <PREFIX> for common case
# <XPREFIX> = <PREFIX>_STATIC for static linking
#
# There are some special variables whose prefix depends on the count
# of given modules. When there is only one module, <PREFIX> stays
# unchanged. When there are multiple modules, the prefix will be
# changed to <PREFIX>_<MODNAME>:
# <XPREFIX>_VERSION ... version of the module
# <XPREFIX>_PREFIX ... prefix-directory of the module
# <XPREFIX>_INCLUDEDIR ... include-dir of the module
# <XPREFIX>_LIBDIR ... lib-dir of the module
#
# <XPREFIX> = <PREFIX> when |MODULES| == 1, else
# <XPREFIX> = <PREFIX>_<MODNAME>
#
# A <MODULE> parameter can have the following formats:
# {MODNAME} ... matches any version
# {MODNAME}>={VERSION} ... at least version <VERSION> is required
# {MODNAME}={VERSION} ... exactly version <VERSION> is required
# {MODNAME}<={VERSION} ... modules must not be newer than <VERSION>
#
# Examples
# pkg_check_modules (GLIB2 glib-2.0)
#
# pkg_check_modules (GLIB2 glib-2.0>=2.10)
# requires at least version 2.10 of glib2 and defines e.g.
# GLIB2_VERSION=2.10.3
#
# pkg_check_modules (FOO glib-2.0>=2.10 gtk+-2.0)
# requires both glib2 and gtk2, and defines e.g.
# FOO_glib-2.0_VERSION=2.10.3
# FOO_gtk+-2.0_VERSION=2.8.20
#
# pkg_check_modules (XRENDER REQUIRED xrender)
# defines e.g.:
# XRENDER_LIBRARIES=Xrender;X11
# XRENDER_STATIC_LIBRARIES=Xrender;X11;pthread;Xau;Xdmcp
#
# pkg_search_module (BAR libxml-2.0 libxml2 libxml>=2)
# Distributed under the OSI-approved BSD 3-Clause License. See accompanying
# file Copyright.txt or https://cmake.org/licensing for details.
#[========================================[.rst:
FindPkgConfig
-------------
# Copyright (C) 2006 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
#
# Redistribution and use, with or without modification, are permitted
# provided that the following conditions are met:
#
# 1. Redistributions must retain the above copyright notice, this
# list of conditions and the following disclaimer.
# 2. The name of the author may not be used to endorse or promote
# products derived from this software without specific prior
# written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
# WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY
# DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
# GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
# IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
# IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
A ``pkg-config`` module for CMake.
Finds the ``pkg-config`` executable and adds the :command:`pkg_get_variable`,
:command:`pkg_check_modules` and :command:`pkg_search_module` commands. The
following variables will also be set:
``PKG_CONFIG_FOUND``
if pkg-config executable was found
``PKG_CONFIG_EXECUTABLE``
pathname of the pkg-config program
``PKG_CONFIG_VERSION_STRING``
version of pkg-config (since CMake 2.8.8)
#]========================================]
### Common stuff ####
set(PKG_CONFIG_VERSION 1)
set(PKG_CONFIG_FOUND 0)
# find pkg-config, use PKG_CONFIG if set
if((NOT PKG_CONFIG_EXECUTABLE) AND (NOT "$ENV{PKG_CONFIG}" STREQUAL ""))
set(PKG_CONFIG_EXECUTABLE "$ENV{PKG_CONFIG}" CACHE FILEPATH "pkg-config executable")
endif()
find_program(PKG_CONFIG_EXECUTABLE NAMES pkg-config DOC "pkg-config executable")
mark_as_advanced(PKG_CONFIG_EXECUTABLE)
if(PKG_CONFIG_EXECUTABLE)
set(PKG_CONFIG_FOUND 1)
endif(PKG_CONFIG_EXECUTABLE)
if (PKG_CONFIG_EXECUTABLE)
execute_process(COMMAND ${PKG_CONFIG_EXECUTABLE} --version
OUTPUT_VARIABLE PKG_CONFIG_VERSION_STRING
ERROR_QUIET
OUTPUT_STRIP_TRAILING_WHITESPACE)
endif ()
include(${CMAKE_CURRENT_LIST_DIR}/FindPackageHandleStandardArgs.cmake)
find_package_handle_standard_args(PkgConfig
REQUIRED_VARS PKG_CONFIG_EXECUTABLE
VERSION_VAR PKG_CONFIG_VERSION_STRING)
# This is needed because the module name is "PkgConfig" but the name of
# this variable has always been PKG_CONFIG_FOUND so this isn't automatically
# handled by FPHSA.
set(PKG_CONFIG_FOUND "${PKGCONFIG_FOUND}")
# Unsets the given variables
macro(_pkgconfig_unset var)
set(${var} "" CACHE INTERNAL "")
endmacro(_pkgconfig_unset)
endmacro()
macro(_pkgconfig_set var value)
set(${var} ${value} CACHE INTERNAL "")
endmacro(_pkgconfig_set)
endmacro()
# Invokes pkgconfig, cleans up the result and sets variables
macro(_pkgconfig_invoke _pkglist _prefix _varname _regexp)
@@ -120,55 +63,311 @@ macro(_pkgconfig_invoke _pkglist _prefix _varname _regexp)
execute_process(
COMMAND ${PKG_CONFIG_EXECUTABLE} ${ARGN} ${_pkglist}
OUTPUT_VARIABLE _pkgconfig_invoke_result
RESULT_VARIABLE _pkgconfig_failed)
RESULT_VARIABLE _pkgconfig_failed
OUTPUT_STRIP_TRAILING_WHITESPACE)
if (_pkgconfig_failed)
set(_pkgconfig_${_varname} "")
_pkgconfig_unset(${_prefix}_${_varname})
else(_pkgconfig_failed)
string(REGEX REPLACE "[\r\n]" " " _pkgconfig_invoke_result "${_pkgconfig_invoke_result}")
string(REGEX REPLACE " +$" "" _pkgconfig_invoke_result "${_pkgconfig_invoke_result}")
else()
string(REGEX REPLACE "[\r\n]" " " _pkgconfig_invoke_result "${_pkgconfig_invoke_result}")
if (NOT ${_regexp} STREQUAL "")
string(REGEX REPLACE "${_regexp}" " " _pkgconfig_invoke_result "${_pkgconfig_invoke_result}")
endif(NOT ${_regexp} STREQUAL "")
endif()
separate_arguments(_pkgconfig_invoke_result)
#message(STATUS " ${_varname} ... ${_pkgconfig_invoke_result}")
set(_pkgconfig_${_varname} ${_pkgconfig_invoke_result})
_pkgconfig_set(${_prefix}_${_varname} "${_pkgconfig_invoke_result}")
endif(_pkgconfig_failed)
endmacro(_pkgconfig_invoke)
endif()
endmacro()
# Internal version of pkg_get_variable; expects PKG_CONFIG_PATH to already be set
function (_pkg_get_variable result pkg variable)
_pkgconfig_invoke("${pkg}" "prefix" "result" "" "--variable=${variable}")
set("${result}"
"${prefix_result}"
PARENT_SCOPE)
endfunction ()
# Invokes pkgconfig two times; once without '--static' and once with
# '--static'
macro(_pkgconfig_invoke_dyn _pkglist _prefix _varname cleanup_regexp)
_pkgconfig_invoke("${_pkglist}" ${_prefix} ${_varname} "${cleanup_regexp}" ${ARGN})
_pkgconfig_invoke("${_pkglist}" ${_prefix} STATIC_${_varname} "${cleanup_regexp}" --static ${ARGN})
endmacro(_pkgconfig_invoke_dyn)
endmacro()
# Splits given arguments into options and a package list
macro(_pkgconfig_parse_options _result _is_req)
macro(_pkgconfig_parse_options _result _is_req _is_silent _no_cmake_path _no_cmake_environment_path _imp_target _imp_target_global)
set(${_is_req} 0)
set(${_is_silent} 0)
set(${_no_cmake_path} 0)
set(${_no_cmake_environment_path} 0)
set(${_imp_target} 0)
set(${_imp_target_global} 0)
if(DEFINED PKG_CONFIG_USE_CMAKE_PREFIX_PATH)
if(NOT PKG_CONFIG_USE_CMAKE_PREFIX_PATH)
set(${_no_cmake_path} 1)
set(${_no_cmake_environment_path} 1)
endif()
elseif(CMAKE_MINIMUM_REQUIRED_VERSION VERSION_LESS 3.1)
set(${_no_cmake_path} 1)
set(${_no_cmake_environment_path} 1)
endif()
foreach(_pkg ${ARGN})
if (_pkg STREQUAL "REQUIRED")
set(${_is_req} 1)
endif (_pkg STREQUAL "REQUIRED")
endforeach(_pkg ${ARGN})
endif ()
if (_pkg STREQUAL "QUIET")
set(${_is_silent} 1)
endif ()
if (_pkg STREQUAL "NO_CMAKE_PATH")
set(${_no_cmake_path} 1)
endif()
if (_pkg STREQUAL "NO_CMAKE_ENVIRONMENT_PATH")
set(${_no_cmake_environment_path} 1)
endif()
if (_pkg STREQUAL "IMPORTED_TARGET")
set(${_imp_target} 1)
endif()
if (_pkg STREQUAL "GLOBAL")
set(${_imp_target_global} 1)
endif()
endforeach()
if (${_imp_target_global} AND NOT ${_imp_target})
message(SEND_ERROR "the argument GLOBAL may only be used together with IMPORTED_TARGET")
endif()
set(${_result} ${ARGN})
list(REMOVE_ITEM ${_result} "REQUIRED")
endmacro(_pkgconfig_parse_options)
list(REMOVE_ITEM ${_result} "QUIET")
list(REMOVE_ITEM ${_result} "NO_CMAKE_PATH")
list(REMOVE_ITEM ${_result} "NO_CMAKE_ENVIRONMENT_PATH")
list(REMOVE_ITEM ${_result} "IMPORTED_TARGET")
list(REMOVE_ITEM ${_result} "GLOBAL")
endmacro()
# Add the content of a variable or an environment variable to a list of
# paths
# Usage:
# - _pkgconfig_add_extra_path(_extra_paths VAR)
# - _pkgconfig_add_extra_path(_extra_paths ENV VAR)
function(_pkgconfig_add_extra_path _extra_paths_var _var)
set(_is_env 0)
if(ARGC GREATER 2 AND _var STREQUAL "ENV")
set(_var ${ARGV2})
set(_is_env 1)
endif()
if(NOT _is_env)
if(NOT "${${_var}}" STREQUAL "")
list(APPEND ${_extra_paths_var} ${${_var}})
endif()
else()
if(NOT "$ENV{${_var}}" STREQUAL "")
file(TO_CMAKE_PATH "$ENV{${_var}}" _path)
list(APPEND ${_extra_paths_var} ${_path})
unset(_path)
endif()
endif()
set(${_extra_paths_var} ${${_extra_paths_var}} PARENT_SCOPE)
endfunction()
# scan the LDFLAGS returned by pkg-config for library directories and
# libraries, figure out the absolute paths of that libraries in the
# given directories
function(_pkg_find_libs _prefix _no_cmake_path _no_cmake_environment_path)
unset(_libs)
unset(_find_opts)
# set the options that are used as long as the .pc file does not provide a library
# path to look into
if(_no_cmake_path)
list(APPEND _find_opts "NO_CMAKE_PATH")
endif()
if(_no_cmake_environment_path)
list(APPEND _find_opts "NO_CMAKE_ENVIRONMENT_PATH")
endif()
unset(_search_paths)
foreach (flag IN LISTS ${_prefix}_LDFLAGS)
if (flag MATCHES "^-L(.*)")
list(APPEND _search_paths ${CMAKE_MATCH_1})
continue()
endif()
if (flag MATCHES "^-l(.*)")
set(_pkg_search "${CMAKE_MATCH_1}")
else()
continue()
endif()
if(_search_paths)
# Firstly search in -L paths
find_library(pkgcfg_lib_${_prefix}_${_pkg_search}
NAMES ${_pkg_search}
HINTS ${_search_paths} NO_DEFAULT_PATH)
endif()
find_library(pkgcfg_lib_${_prefix}_${_pkg_search}
NAMES ${_pkg_search}
${_find_opts})
mark_as_advanced(pkgcfg_lib_${_prefix}_${_pkg_search})
if(pkgcfg_lib_${_prefix}_${_pkg_search})
list(APPEND _libs "${pkgcfg_lib_${_prefix}_${_pkg_search}}")
else()
list(APPEND _libs ${_pkg_search})
endif()
endforeach()
set(${_prefix}_LINK_LIBRARIES "${_libs}" PARENT_SCOPE)
endfunction()
# create an imported target from all the information returned by pkg-config
function(_pkg_create_imp_target _prefix _imp_target_global)
# only create the target if it is linkable, i.e. no executables
if (NOT TARGET PkgConfig::${_prefix}
AND ( ${_prefix}_INCLUDE_DIRS OR ${_prefix}_LINK_LIBRARIES OR ${_prefix}_LDFLAGS_OTHER OR ${_prefix}_CFLAGS_OTHER ))
if(${_imp_target_global})
set(_global_opt "GLOBAL")
else()
unset(_global_opt)
endif()
add_library(PkgConfig::${_prefix} INTERFACE IMPORTED ${_global_opt})
if(${_prefix}_INCLUDE_DIRS)
set_property(TARGET PkgConfig::${_prefix} PROPERTY
INTERFACE_INCLUDE_DIRECTORIES "${${_prefix}_INCLUDE_DIRS}")
endif()
if(${_prefix}_LINK_LIBRARIES)
set_property(TARGET PkgConfig::${_prefix} PROPERTY
INTERFACE_LINK_LIBRARIES "${${_prefix}_LINK_LIBRARIES}")
endif()
if(${_prefix}_LDFLAGS_OTHER)
set_property(TARGET PkgConfig::${_prefix} PROPERTY
INTERFACE_LINK_OPTIONS "${${_prefix}_LDFLAGS_OTHER}")
endif()
if(${_prefix}_CFLAGS_OTHER)
set_property(TARGET PkgConfig::${_prefix} PROPERTY
INTERFACE_COMPILE_OPTIONS "${${_prefix}_CFLAGS_OTHER}")
endif()
endif()
endfunction()
# recalculate the dynamic output
# this is a macro and not a function so the result of _pkg_find_libs is automatically propagated
macro(_pkg_recalculate _prefix _no_cmake_path _no_cmake_environment_path _imp_target _imp_target_global)
_pkg_find_libs(${_prefix} ${_no_cmake_path} ${_no_cmake_environment_path})
if(${_imp_target})
_pkg_create_imp_target(${_prefix} ${_imp_target_global})
endif()
endmacro()
###
macro(_pkg_check_modules_internal _is_required _is_silent _prefix)
macro(_pkg_set_path_internal)
set(_extra_paths)
if(NOT _no_cmake_path)
_pkgconfig_add_extra_path(_extra_paths CMAKE_PREFIX_PATH)
_pkgconfig_add_extra_path(_extra_paths CMAKE_FRAMEWORK_PATH)
_pkgconfig_add_extra_path(_extra_paths CMAKE_APPBUNDLE_PATH)
endif()
if(NOT _no_cmake_environment_path)
_pkgconfig_add_extra_path(_extra_paths ENV CMAKE_PREFIX_PATH)
_pkgconfig_add_extra_path(_extra_paths ENV CMAKE_FRAMEWORK_PATH)
_pkgconfig_add_extra_path(_extra_paths ENV CMAKE_APPBUNDLE_PATH)
endif()
if(NOT _extra_paths STREQUAL "")
# Save the PKG_CONFIG_PATH environment variable, and add paths
# from the CMAKE_PREFIX_PATH variables
set(_pkgconfig_path_old "$ENV{PKG_CONFIG_PATH}")
set(_pkgconfig_path "${_pkgconfig_path_old}")
if(NOT _pkgconfig_path STREQUAL "")
file(TO_CMAKE_PATH "${_pkgconfig_path}" _pkgconfig_path)
endif()
# Create a list of the possible pkgconfig subfolder (depending on
# the system
set(_lib_dirs)
if(NOT DEFINED CMAKE_SYSTEM_NAME
OR (CMAKE_SYSTEM_NAME MATCHES "^(Linux|kFreeBSD|GNU)$"
AND NOT CMAKE_CROSSCOMPILING))
if(EXISTS "/etc/debian_version") # is this a debian system ?
if(CMAKE_LIBRARY_ARCHITECTURE)
list(APPEND _lib_dirs "lib/${CMAKE_LIBRARY_ARCHITECTURE}/pkgconfig")
endif()
else()
# not debian, check the FIND_LIBRARY_USE_LIB32_PATHS and FIND_LIBRARY_USE_LIB64_PATHS properties
get_property(uselib32 GLOBAL PROPERTY FIND_LIBRARY_USE_LIB32_PATHS)
if(uselib32 AND CMAKE_SIZEOF_VOID_P EQUAL 4)
list(APPEND _lib_dirs "lib32/pkgconfig")
endif()
get_property(uselib64 GLOBAL PROPERTY FIND_LIBRARY_USE_LIB64_PATHS)
if(uselib64 AND CMAKE_SIZEOF_VOID_P EQUAL 8)
list(APPEND _lib_dirs "lib64/pkgconfig")
endif()
get_property(uselibx32 GLOBAL PROPERTY FIND_LIBRARY_USE_LIBX32_PATHS)
if(uselibx32 AND CMAKE_INTERNAL_PLATFORM_ABI STREQUAL "ELF X32")
list(APPEND _lib_dirs "libx32/pkgconfig")
endif()
endif()
endif()
if(CMAKE_SYSTEM_NAME STREQUAL "FreeBSD" AND NOT CMAKE_CROSSCOMPILING)
list(APPEND _lib_dirs "libdata/pkgconfig")
endif()
list(APPEND _lib_dirs "lib/pkgconfig")
list(APPEND _lib_dirs "share/pkgconfig")
# Check if directories exist and eventually append them to the
# pkgconfig path list
foreach(_prefix_dir ${_extra_paths})
foreach(_lib_dir ${_lib_dirs})
if(EXISTS "${_prefix_dir}/${_lib_dir}")
list(APPEND _pkgconfig_path "${_prefix_dir}/${_lib_dir}")
list(REMOVE_DUPLICATES _pkgconfig_path)
endif()
endforeach()
endforeach()
# Prepare and set the environment variable
if(NOT _pkgconfig_path STREQUAL "")
# remove empty values from the list
list(REMOVE_ITEM _pkgconfig_path "")
file(TO_NATIVE_PATH "${_pkgconfig_path}" _pkgconfig_path)
if(UNIX)
string(REPLACE ";" ":" _pkgconfig_path "${_pkgconfig_path}")
string(REPLACE "\\ " " " _pkgconfig_path "${_pkgconfig_path}")
endif()
set(ENV{PKG_CONFIG_PATH} "${_pkgconfig_path}")
endif()
# Unset variables
unset(_lib_dirs)
unset(_pkgconfig_path)
endif()
endmacro()
macro(_pkg_restore_path_internal)
if(NOT _extra_paths STREQUAL "")
# Restore the environment variable
set(ENV{PKG_CONFIG_PATH} "${_pkgconfig_path_old}")
endif()
unset(_extra_paths)
unset(_pkgconfig_path_old)
endmacro()
###
macro(_pkg_check_modules_internal _is_required _is_silent _no_cmake_path _no_cmake_environment_path _imp_target _imp_target_global _prefix)
_pkgconfig_unset(${_prefix}_FOUND)
_pkgconfig_unset(${_prefix}_VERSION)
_pkgconfig_unset(${_prefix}_PREFIX)
_pkgconfig_unset(${_prefix}_INCLUDEDIR)
_pkgconfig_unset(${_prefix}_LIBDIR)
_pkgconfig_unset(${_prefix}_MODULE_NAME)
_pkgconfig_unset(${_prefix}_LIBS)
_pkgconfig_unset(${_prefix}_LIBS_L)
_pkgconfig_unset(${_prefix}_LIBS_PATHS)
@@ -193,83 +392,77 @@ macro(_pkg_check_modules_internal _is_required _is_silent _prefix)
# give out status message telling checked module
if (NOT ${_is_silent})
if (_pkg_check_modules_cnt EQUAL 1)
message(STATUS "checking for module '${_pkg_check_modules_list}'")
else(_pkg_check_modules_cnt EQUAL 1)
message(STATUS "checking for modules '${_pkg_check_modules_list}'")
endif(_pkg_check_modules_cnt EQUAL 1)
endif(NOT ${_is_silent})
message(STATUS "Checking for module '${_pkg_check_modules_list}'")
else()
message(STATUS "Checking for modules '${_pkg_check_modules_list}'")
endif()
endif()
set(_pkg_check_modules_packages)
set(_pkg_check_modules_failed)
_pkg_set_path_internal()
# iterate through module list and check whether they exist and match the required version
foreach (_pkg_check_modules_pkg ${_pkg_check_modules_list})
set(_pkg_check_modules_exist_query)
# check whether version is given
if (_pkg_check_modules_pkg MATCHES ".*(>=|=|<=).*")
string(REGEX REPLACE "(.*[^><])(>=|=|<=)(.*)" "\\1" _pkg_check_modules_pkg_name "${_pkg_check_modules_pkg}")
string(REGEX REPLACE "(.*[^><])(>=|=|<=)(.*)" "\\2" _pkg_check_modules_pkg_op "${_pkg_check_modules_pkg}")
string(REGEX REPLACE "(.*[^><])(>=|=|<=)(.*)" "\\3" _pkg_check_modules_pkg_ver "${_pkg_check_modules_pkg}")
else(_pkg_check_modules_pkg MATCHES ".*(>=|=|<=).*")
if (_pkg_check_modules_pkg MATCHES "(.*[^><])(=|[><]=?)(.*)")
set(_pkg_check_modules_pkg_name "${CMAKE_MATCH_1}")
set(_pkg_check_modules_pkg_op "${CMAKE_MATCH_2}")
set(_pkg_check_modules_pkg_ver "${CMAKE_MATCH_3}")
else()
set(_pkg_check_modules_pkg_name "${_pkg_check_modules_pkg}")
set(_pkg_check_modules_pkg_op)
set(_pkg_check_modules_pkg_ver)
endif(_pkg_check_modules_pkg MATCHES ".*(>=|=|<=).*")
# handle the operands
if (_pkg_check_modules_pkg_op STREQUAL ">=")
list(APPEND _pkg_check_modules_exist_query --atleast-version)
endif(_pkg_check_modules_pkg_op STREQUAL ">=")
if (_pkg_check_modules_pkg_op STREQUAL "=")
list(APPEND _pkg_check_modules_exist_query --exact-version)
endif(_pkg_check_modules_pkg_op STREQUAL "=")
if (_pkg_check_modules_pkg_op STREQUAL "<=")
list(APPEND _pkg_check_modules_exist_query --max-version)
endif(_pkg_check_modules_pkg_op STREQUAL "<=")
# create the final query which is of the format:
# * --atleast-version <version> <pkg-name>
# * --exact-version <version> <pkg-name>
# * --max-version <version> <pkg-name>
# * --exists <pkg-name>
if (_pkg_check_modules_pkg_op)
list(APPEND _pkg_check_modules_exist_query "${_pkg_check_modules_pkg_ver}")
else(_pkg_check_modules_pkg_op)
list(APPEND _pkg_check_modules_exist_query --exists)
endif(_pkg_check_modules_pkg_op)
endif()
_pkgconfig_unset(${_prefix}_${_pkg_check_modules_pkg_name}_VERSION)
_pkgconfig_unset(${_prefix}_${_pkg_check_modules_pkg_name}_PREFIX)
_pkgconfig_unset(${_prefix}_${_pkg_check_modules_pkg_name}_INCLUDEDIR)
_pkgconfig_unset(${_prefix}_${_pkg_check_modules_pkg_name}_LIBDIR)
list(APPEND _pkg_check_modules_exist_query "${_pkg_check_modules_pkg_name}")
list(APPEND _pkg_check_modules_packages "${_pkg_check_modules_pkg_name}")
# create the final query which is of the format:
# * <pkg-name> > <version>
# * <pkg-name> >= <version>
# * <pkg-name> = <version>
# * <pkg-name> <= <version>
# * <pkg-name> < <version>
# * --exists <pkg-name>
list(APPEND _pkg_check_modules_exist_query --print-errors --short-errors)
if (_pkg_check_modules_pkg_op)
list(APPEND _pkg_check_modules_exist_query "${_pkg_check_modules_pkg_name} ${_pkg_check_modules_pkg_op} ${_pkg_check_modules_pkg_ver}")
else()
list(APPEND _pkg_check_modules_exist_query --exists)
list(APPEND _pkg_check_modules_exist_query "${_pkg_check_modules_pkg_name}")
endif()
# execute the query
execute_process(
COMMAND ${PKG_CONFIG_EXECUTABLE} ${_pkg_check_modules_exist_query}
RESULT_VARIABLE _pkgconfig_retval)
RESULT_VARIABLE _pkgconfig_retval
ERROR_VARIABLE _pkgconfig_error
ERROR_STRIP_TRAILING_WHITESPACE)
# evaluate result and tell failures
if (_pkgconfig_retval)
if(NOT ${_is_silent})
message(STATUS " package '${_pkg_check_modules_pkg}' not found")
endif(NOT ${_is_silent})
message(STATUS " ${_pkgconfig_error}")
endif()
set(_pkg_check_modules_failed 1)
endif(_pkgconfig_retval)
endforeach(_pkg_check_modules_pkg)
endif()
endforeach()
if(_pkg_check_modules_failed)
# fail when requested
if (${_is_required})
message(SEND_ERROR "A required package was not found")
endif (${_is_required})
else(_pkg_check_modules_failed)
message(FATAL_ERROR "A required package was not found")
endif ()
else()
# when we are here, we checked whether requested modules
# exist. Now, go through them and set variables
@@ -281,17 +474,23 @@ macro(_pkg_check_modules_internal _is_required _is_silent _prefix)
# handle case when there is only one package required
if (pkg_count EQUAL 1)
set(_pkg_check_prefix "${_prefix}")
else(pkg_count EQUAL 1)
else()
set(_pkg_check_prefix "${_prefix}_${_pkg_check_modules_pkg}")
endif(pkg_count EQUAL 1)
endif()
_pkgconfig_invoke(${_pkg_check_modules_pkg} "${_pkg_check_prefix}" VERSION "" --modversion )
_pkgconfig_invoke(${_pkg_check_modules_pkg} "${_pkg_check_prefix}" PREFIX "" --variable=prefix )
_pkgconfig_invoke(${_pkg_check_modules_pkg} "${_pkg_check_prefix}" INCLUDEDIR "" --variable=includedir )
_pkgconfig_invoke(${_pkg_check_modules_pkg} "${_pkg_check_prefix}" LIBDIR "" --variable=libdir )
pkg_get_variable("${_pkg_check_prefix}_PREFIX" ${_pkg_check_modules_pkg} "prefix")
pkg_get_variable("${_pkg_check_prefix}_INCLUDEDIR" ${_pkg_check_modules_pkg} "includedir")
pkg_get_variable("${_pkg_check_prefix}_LIBDIR" ${_pkg_check_modules_pkg} "libdir")
foreach (variable IN ITEMS PREFIX INCLUDEDIR LIBDIR)
_pkgconfig_set("${_pkg_check_prefix}_${variable}" "${${_pkg_check_prefix}_${variable}}")
endforeach ()
_pkgconfig_set("${_pkg_check_prefix}_MODULE_NAME" "${_pkg_check_modules_pkg}")
message(STATUS " found ${_pkg_check_modules_pkg}, version ${_pkgconfig_VERSION}")
endforeach(_pkg_check_modules_pkg)
if (NOT ${_is_silent})
message(STATUS " Found ${_pkg_check_modules_pkg}, version ${_pkgconfig_VERSION}")
endif ()
endforeach()
# set variables which are combined for multiple modules
_pkgconfig_invoke_dyn("${_pkg_check_modules_packages}" "${_prefix}" LIBRARIES "(^| )-l" --libs-only-l )
@@ -302,58 +501,271 @@ macro(_pkg_check_modules_internal _is_required _is_silent _prefix)
_pkgconfig_invoke_dyn("${_pkg_check_modules_packages}" "${_prefix}" INCLUDE_DIRS "(^| )-I" --cflags-only-I )
_pkgconfig_invoke_dyn("${_pkg_check_modules_packages}" "${_prefix}" CFLAGS "" --cflags )
_pkgconfig_invoke_dyn("${_pkg_check_modules_packages}" "${_prefix}" CFLAGS_OTHER "" --cflags-only-other )
endif(_pkg_check_modules_failed)
else(PKG_CONFIG_EXECUTABLE)
_pkg_recalculate("${_prefix}" ${_no_cmake_path} ${_no_cmake_environment_path} ${_imp_target} ${_imp_target_global})
endif()
_pkg_restore_path_internal()
else()
if (${_is_required})
message(SEND_ERROR "pkg-config tool not found")
endif (${_is_required})
endif(PKG_CONFIG_EXECUTABLE)
endmacro(_pkg_check_modules_internal)
endif ()
endif()
endmacro()
###
### User visible macros start here
###
###
#[========================================[.rst:
.. command:: pkg_check_modules
Checks for all the given modules, setting a variety of result variables in
the calling scope.
.. code-block:: cmake
pkg_check_modules(<prefix>
[REQUIRED] [QUIET]
[NO_CMAKE_PATH]
[NO_CMAKE_ENVIRONMENT_PATH]
[IMPORTED_TARGET [GLOBAL]]
<moduleSpec> [<moduleSpec>...])
When the ``REQUIRED`` argument is given, the command will fail with an error
if module(s) could not be found.
When the ``QUIET`` argument is given, no status messages will be printed.
By default, if :variable:`CMAKE_MINIMUM_REQUIRED_VERSION` is 3.1 or
later, or if :variable:`PKG_CONFIG_USE_CMAKE_PREFIX_PATH` is set to a
boolean ``True`` value, then the :variable:`CMAKE_PREFIX_PATH`,
:variable:`CMAKE_FRAMEWORK_PATH`, and :variable:`CMAKE_APPBUNDLE_PATH` cache
and environment variables will be added to the ``pkg-config`` search path.
The ``NO_CMAKE_PATH`` and ``NO_CMAKE_ENVIRONMENT_PATH`` arguments
disable this behavior for the cache variables and environment variables
respectively.
The ``IMPORTED_TARGET`` argument will create an imported target named
``PkgConfig::<prefix>`` that can be passed directly as an argument to
:command:`target_link_libraries`. The ``GLOBAL`` argument will make the
imported target available in global scope.
Each ``<moduleSpec>`` can be either a bare module name or it can be a
module name with a version constraint (operators ``=``, ``<``, ``>``,
``<=`` and ``>=`` are supported). The following are examples for a module
named ``foo`` with various constraints:
- ``foo`` matches any version.
- ``foo<2`` only matches versions before 2.
- ``foo>=3.1`` matches any version from 3.1 or later.
- ``foo=1.2.3`` requires that foo must be exactly version 1.2.3.
The following variables may be set upon return. Two sets of values exist:
One for the common case (``<XXX> = <prefix>``) and another for the
information ``pkg-config`` provides when called with the ``--static``
option (``<XXX> = <prefix>_STATIC``).
``<XXX>_FOUND``
set to 1 if module(s) exist
``<XXX>_LIBRARIES``
only the libraries (without the '-l')
``<XXX>_LINK_LIBRARIES``
the libraries and their absolute paths
``<XXX>_LIBRARY_DIRS``
the paths of the libraries (without the '-L')
``<XXX>_LDFLAGS``
all required linker flags
``<XXX>_LDFLAGS_OTHER``
all other linker flags
``<XXX>_INCLUDE_DIRS``
the '-I' preprocessor flags (without the '-I')
``<XXX>_CFLAGS``
all required cflags
``<XXX>_CFLAGS_OTHER``
the other compiler flags
All but ``<XXX>_FOUND`` may be a :ref:`;-list <CMake Language Lists>` if the
associated variable returned from ``pkg-config`` has multiple values.
There are some special variables whose prefix depends on the number of
``<moduleSpec>`` given. When there is only one ``<moduleSpec>``,
``<YYY>`` will simply be ``<prefix>``, but if two or more ``<moduleSpec>``
items are given, ``<YYY>`` will be ``<prefix>_<moduleName>``.
``<YYY>_VERSION``
version of the module
``<YYY>_PREFIX``
prefix directory of the module
``<YYY>_INCLUDEDIR``
include directory of the module
``<YYY>_LIBDIR``
lib directory of the module
Examples:
.. code-block:: cmake
pkg_check_modules (GLIB2 glib-2.0)
Looks for any version of glib2. If found, the output variable
``GLIB2_VERSION`` will hold the actual version found.
.. code-block:: cmake
pkg_check_modules (GLIB2 glib-2.0>=2.10)
Looks for at least version 2.10 of glib2. If found, the output variable
``GLIB2_VERSION`` will hold the actual version found.
.. code-block:: cmake
pkg_check_modules (FOO glib-2.0>=2.10 gtk+-2.0)
Looks for both glib2-2.0 (at least version 2.10) and any version of
gtk2+-2.0. Only if both are found will ``FOO`` be considered found.
The ``FOO_glib-2.0_VERSION`` and ``FOO_gtk+-2.0_VERSION`` variables will be
set to their respective found module versions.
.. code-block:: cmake
pkg_check_modules (XRENDER REQUIRED xrender)
Requires any version of ``xrender``. Example output variables set by a
successful call::
XRENDER_LIBRARIES=Xrender;X11
XRENDER_STATIC_LIBRARIES=Xrender;X11;pthread;Xau;Xdmcp
#]========================================]
macro(pkg_check_modules _prefix _module0)
_pkgconfig_parse_options(_pkg_modules _pkg_is_required _pkg_is_silent _no_cmake_path _no_cmake_environment_path _imp_target _imp_target_global "${_module0}" ${ARGN})
# check cached value
if (NOT DEFINED __pkg_config_checked_${_prefix} OR __pkg_config_checked_${_prefix} LESS ${PKG_CONFIG_VERSION})
_pkgconfig_parse_options (_pkg_modules _pkg_is_required "${_module0}" ${ARGN})
_pkg_check_modules_internal("${_pkg_is_required}" 0 "${_prefix}" ${_pkg_modules})
if (NOT DEFINED __pkg_config_checked_${_prefix} OR __pkg_config_checked_${_prefix} LESS ${PKG_CONFIG_VERSION} OR NOT ${_prefix}_FOUND OR
(NOT "${ARGN}" STREQUAL "" AND NOT "${__pkg_config_arguments_${_prefix}}" STREQUAL "${_module0};${ARGN}") OR
( "${ARGN}" STREQUAL "" AND NOT "${__pkg_config_arguments_${_prefix}}" STREQUAL "${_module0}"))
_pkg_check_modules_internal("${_pkg_is_required}" "${_pkg_is_silent}" ${_no_cmake_path} ${_no_cmake_environment_path} ${_imp_target} ${_imp_target_global} "${_prefix}" ${_pkg_modules})
_pkgconfig_set(__pkg_config_checked_${_prefix} ${PKG_CONFIG_VERSION})
endif(NOT DEFINED __pkg_config_checked_${_prefix} OR __pkg_config_checked_${_prefix} LESS ${PKG_CONFIG_VERSION})
endmacro(pkg_check_modules)
if (${_prefix}_FOUND)
_pkgconfig_set(__pkg_config_arguments_${_prefix} "${_module0};${ARGN}")
endif()
else()
if (${_prefix}_FOUND)
_pkg_recalculate("${_prefix}" ${_no_cmake_path} ${_no_cmake_environment_path} ${_imp_target} ${_imp_target_global})
endif()
endif()
endmacro()
###
#[========================================[.rst:
.. command:: pkg_search_module
The behavior of this command is the same as :command:`pkg_check_modules`,
except that rather than checking for all the specified modules, it searches
for just the first successful match.
.. code-block:: cmake
pkg_search_module(<prefix>
[REQUIRED] [QUIET]
[NO_CMAKE_PATH]
[NO_CMAKE_ENVIRONMENT_PATH]
[IMPORTED_TARGET [GLOBAL]]
<moduleSpec> [<moduleSpec>...])
If a module is found, the ``<prefix>_MODULE_NAME`` variable will contain the
name of the matching module. This variable can be used if you need to run
:command:`pkg_get_variable`.
Example:
.. code-block:: cmake
pkg_search_module (BAR libxml-2.0 libxml2 libxml>=2)
#]========================================]
macro(pkg_search_module _prefix _module0)
_pkgconfig_parse_options(_pkg_modules_alt _pkg_is_required _pkg_is_silent _no_cmake_path _no_cmake_environment_path _imp_target _imp_target_global "${_module0}" ${ARGN})
# check cached value
if (NOT DEFINED __pkg_config_checked_${_prefix} OR __pkg_config_checked_${_prefix} LESS ${PKG_CONFIG_VERSION} OR NOT ${_prefix}_FOUND)
set(_pkg_modules_found 0)
_pkgconfig_parse_options(_pkg_modules_alt _pkg_is_required "${_module0}" ${ARGN})
message(STATUS "checking for one of the modules '${_pkg_modules_alt}'")
if (NOT ${_pkg_is_silent})
message(STATUS "Checking for one of the modules '${_pkg_modules_alt}'")
endif ()
# iterate through all modules and stop at the first working one.
foreach(_pkg_alt ${_pkg_modules_alt})
if(NOT _pkg_modules_found)
_pkg_check_modules_internal(0 1 "${_prefix}" "${_pkg_alt}")
endif(NOT _pkg_modules_found)
_pkg_check_modules_internal(0 1 ${_no_cmake_path} ${_no_cmake_environment_path} ${_imp_target} ${_imp_target_global} "${_prefix}" "${_pkg_alt}")
endif()
if (${_prefix}_FOUND)
set(_pkg_modules_found 1)
endif(${_prefix}_FOUND)
endforeach(_pkg_alt)
break()
endif()
endforeach()
if (NOT ${_prefix}_FOUND)
if(${_pkg_is_required})
message(SEND_ERROR "None of the required '${_pkg_modules_alt}' found")
endif(${_pkg_is_required})
endif(NOT ${_prefix}_FOUND)
endif()
endif()
_pkgconfig_set(__pkg_config_checked_${_prefix} ${PKG_CONFIG_VERSION})
endif(NOT DEFINED __pkg_config_checked_${_prefix} OR __pkg_config_checked_${_prefix} LESS ${PKG_CONFIG_VERSION} OR NOT ${_prefix}_FOUND)
endmacro(pkg_search_module)
elseif (${_prefix}_FOUND)
_pkg_recalculate("${_prefix}" ${_no_cmake_path} ${_no_cmake_environment_path} ${_imp_target} ${_imp_target_global})
endif()
endmacro()
#[========================================[.rst:
.. command:: pkg_get_variable
Retrieves the value of a pkg-config variable ``varName`` and stores it in the
result variable ``resultVar`` in the calling scope.
.. code-block:: cmake
pkg_get_variable(<resultVar> <moduleName> <varName>)
If ``pkg-config`` returns multiple values for the specified variable,
``resultVar`` will contain a :ref:`;-list <CMake Language Lists>`.
For example:
.. code-block:: cmake
pkg_get_variable(GI_GIRDIR gobject-introspection-1.0 girdir)
#]========================================]
function (pkg_get_variable result pkg variable)
_pkg_set_path_internal()
_pkgconfig_invoke("${pkg}" "prefix" "result" "" "--variable=${variable}")
set("${result}"
"${prefix_result}"
PARENT_SCOPE)
_pkg_restore_path_internal()
endfunction ()
#[========================================[.rst:
Variables Affecting Behavior
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
.. variable:: PKG_CONFIG_EXECUTABLE
This can be set to the path of the pkg-config executable. If not provided,
it will be set by the module as a result of calling :command:`find_program`
internally. The ``PKG_CONFIG`` environment variable can be used as a hint.
.. variable:: PKG_CONFIG_USE_CMAKE_PREFIX_PATH
Specifies whether :command:`pkg_check_modules` and
:command:`pkg_search_module` should add the paths in the
:variable:`CMAKE_PREFIX_PATH`, :variable:`CMAKE_FRAMEWORK_PATH` and
:variable:`CMAKE_APPBUNDLE_PATH` cache and environment variables to the
``pkg-config`` search path.
If this variable is not set, this behavior is enabled by default if
:variable:`CMAKE_MINIMUM_REQUIRED_VERSION` is 3.1 or later, disabled
otherwise.
#]========================================]
### Local Variables:
### mode: cmake
+6 -3
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2009 Julien Louis <ptitlouis@sysif.net>
#
# This file is part of WeeChat, the extensible chat client.
@@ -31,7 +31,10 @@
include(FindPkgConfig)
if(ENABLE_PYTHON2)
pkg_check_modules(PYTHON python2)
pkg_check_modules(PYTHON python2 IMPORTED_TARGET GLOBAL)
else()
pkg_check_modules(PYTHON python3)
pkg_check_modules(PYTHON python3-embed IMPORTED_TARGET GLOBAL)
if(NOT PYTHON_FOUND)
pkg_check_modules(PYTHON python3 IMPORTED_TARGET GLOBAL)
endif()
endif()
+14 -14
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -27,13 +27,13 @@
# RUBY_LIB = ruby library (found without pkg-config)
if(RUBY_FOUND)
# Already in cache, be silent
set(RUBY_FIND_QUIETLY TRUE)
# Already in cache, be silent
set(RUBY_FIND_QUIETLY TRUE)
endif()
find_package(PkgConfig)
if(PKG_CONFIG_FOUND)
pkg_search_module(RUBY ruby-2.6 ruby-2.5 ruby-2.4 ruby-2.3 ruby-2.2 ruby-2.1 ruby-2.0 ruby-1.9 ruby-1.8)
pkg_search_module(RUBY ruby-2.7 ruby-2.6 ruby-2.5 ruby-2.4 ruby-2.3 ruby-2.2 ruby-2.1 ruby-2.0 ruby-1.9)
endif()
if(RUBY_FOUND)
@@ -41,35 +41,35 @@ if(RUBY_FOUND)
mark_as_advanced(RUBY_LIB)
else()
find_program(RUBY_EXECUTABLE
NAMES ruby2.6.0 ruby260 ruby2.6 ruby2.5.0 ruby250 ruby2.5 ruby2.4.0 ruby240 ruby2.4 ruby2.3.0 ruby230 ruby2.3 ruby23 ruby2.2.3 ruby223 ruby2.2.2 ruby222 ruby2.2.1 ruby221 ruby2.2.0 ruby220 ruby2.2 ruby22 ruby2.1.7 ruby217 ruby2.1.6 ruby216 ruby2.1.5 ruby215 ruby2.1.4 ruby214 ruby2.1.3 ruby213 ruby2.1.2 ruby212 ruby2.1.1 ruby211 ruby2.1.0 ruby210 ruby2.1 ruby21 ruby2.0 ruby20 ruby1.9.3 ruby193 ruby1.9.2 ruby192 ruby1.9.1 ruby191 ruby1.9 ruby19 ruby1.8 ruby18 ruby
NAMES ruby2.7.0 ruby270 ruby2.7 ruby2.6.0 ruby260 ruby2.6 ruby2.5.0 ruby250 ruby2.5 ruby2.4.0 ruby240 ruby2.4 ruby2.3.0 ruby230 ruby2.3 ruby23 ruby2.2.3 ruby223 ruby2.2.2 ruby222 ruby2.2.1 ruby221 ruby2.2.0 ruby220 ruby2.2 ruby22 ruby2.1.7 ruby217 ruby2.1.6 ruby216 ruby2.1.5 ruby215 ruby2.1.4 ruby214 ruby2.1.3 ruby213 ruby2.1.2 ruby212 ruby2.1.1 ruby211 ruby2.1.0 ruby210 ruby2.1 ruby21 ruby2.0 ruby20 ruby1.9.3 ruby193 ruby1.9.2 ruby192 ruby1.9.1 ruby191 ruby1.9 ruby19 ruby
PATHS /usr/bin /usr/local/bin /usr/pkg/bin
)
)
if(RUBY_EXECUTABLE)
execute_process(
COMMAND ${RUBY_EXECUTABLE} -r rbconfig -e "print RbConfig::CONFIG['rubyhdrdir'] || RbConfig::CONFIG['archdir']"
OUTPUT_VARIABLE RUBY_ARCH_DIR
)
)
execute_process(
COMMAND ${RUBY_EXECUTABLE} -r rbconfig -e "print RbConfig::CONFIG['arch']"
OUTPUT_VARIABLE RUBY_ARCH
)
)
execute_process(
COMMAND ${RUBY_EXECUTABLE} -r rbconfig -e "print RbConfig::CONFIG['libdir']"
OUTPUT_VARIABLE RUBY_POSSIBLE_LIB_PATH
)
)
execute_process(
COMMAND ${RUBY_EXECUTABLE} -r rbconfig -e "print RbConfig::CONFIG['rubylibdir']"
OUTPUT_VARIABLE RUBY_RUBY_LIB_PATH
)
)
find_path(RUBY_INCLUDE_DIRS
NAMES ruby.h
PATHS ${RUBY_ARCH_DIR}
)
)
set(RUBY_INCLUDE_ARCH "${RUBY_INCLUDE_DIRS}/${RUBY_ARCH}")
find_library(RUBY_LIB
NAMES ruby-1.9.3 ruby1.9.3 ruby193 ruby-1.9.2 ruby1.9.2 ruby192 ruby-1.9.1 ruby1.9.1 ruby191 ruby1.9 ruby19 ruby1.8 ruby18 ruby
NAMES ruby-1.9.3 ruby1.9.3 ruby193 ruby-1.9.2 ruby1.9.2 ruby192 ruby-1.9.1 ruby1.9.1 ruby191 ruby1.9 ruby19 ruby
PATHS ${RUBY_POSSIBLE_LIB_PATH} ${RUBY_RUBY_LIB_PATH}
)
)
if(RUBY_LIB AND RUBY_INCLUDE_DIRS)
set(RUBY_FOUND TRUE)
endif()
@@ -78,6 +78,6 @@ else()
RUBY_INCLUDE_DIRS
RUBY_LIBRARY_DIRS
RUBY_LIB
)
)
endif()
endif()
-162
View File
@@ -1,162 +0,0 @@
#
# Copyright (C) 2008 Julien Louis <ptitlouis@sysif.net>
# Copyright (C) 2008-2019 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
# WeeChat is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 3 of the License, or
# (at your option) any later version.
#
# WeeChat is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with WeeChat. If not, see <https://www.gnu.org/licenses/>.
#
# - Find Tcl includes and libraries.
# This module finds if Tcl is installed and determines where the
# include files and libraries are. It also determines what the name of
# the library is. This code sets the following variables:
# TCL_FOUND = Tcl was found
# TK_FOUND = Tk was found
# TCLTK_FOUND = Tcl and Tk were found
# TCL_LIBRARY = path to Tcl library (tcl tcl80)
# TCL_INCLUDE_PATH = path to where tcl.h can be found
# TCL_TCLSH = path to tclsh binary (tcl tcl80)
# TK_LIBRARY = path to Tk library (tk tk80 etc)
# TK_INCLUDE_PATH = path to where tk.h can be found
# TK_WISH = full path to the wish executable
#
# In an effort to remove some clutter and clear up some issues for people
# who are not necessarily Tcl/Tk gurus/developpers, some variables were
# moved or removed. Changes compared to CMake 2.4 are:
# - The stub libraries are now found in FindTclStub.cmake
# => they were only useful for people writing Tcl/Tk extensions.
# - TCL_LIBRARY_DEBUG and TK_LIBRARY_DEBUG were removed.
# => these libs are not packaged by default with Tcl/Tk distributions.
# Even when Tcl/Tk is built from source, several flavors of debug libs
# are created and there is no real reason to pick a single one
# specifically (say, amongst tcl84g, tcl84gs, or tcl84sgx).
# Let's leave that choice to the user by allowing him to assign
# TCL_LIBRARY to any Tcl library, debug or not.
# - TK_INTERNAL_PATH was removed.
# => this ended up being only a Win32 variable, and there is a lot of
# confusion regarding the location of this file in an installed Tcl/Tk
# tree anyway (see 8.5 for example). If you need the internal path at
# this point it is safer you ask directly where the *source* tree is
# and dig from there.
if(TCL_FOUND)
set(TCL_FIND_QUIETLY TRUE)
endif()
include(CMakeFindFrameworks)
include(FindTclsh)
get_filename_component(TCL_TCLSH_PATH "${TCL_TCLSH}" PATH)
get_filename_component(TCL_TCLSH_PATH_PARENT "${TCL_TCLSH_PATH}" PATH)
string(REGEX REPLACE
"^.*tclsh([0-9]\\.*[0-9]).*$" "\\1" TCL_TCLSH_VERSION "${TCL_TCLSH}")
get_filename_component(TCL_INCLUDE_PATH_PARENT "${TCL_INCLUDE_PATH}" PATH)
get_filename_component(TCL_LIBRARY_PATH "${TCL_LIBRARY}" PATH)
get_filename_component(TCL_LIBRARY_PATH_PARENT "${TCL_LIBRARY_PATH}" PATH)
string(REGEX REPLACE
"^.*tcl([0-9]\\.*[0-9]).*$" "\\1" TCL_VERSION "${TCL_LIBRARY}")
set(TCL_POSSIBLE_LIB_PATHS
"${TCL_INCLUDE_PATH_PARENT}/lib"
"${TCL_INCLUDE_PATH_PARENT}/lib64"
"${TCL_LIBRARY_PATH}"
"${TCL_TCLSH_PATH_PARENT}/lib"
"${TCL_TCLSH_PATH_PARENT}/lib64"
/usr/lib
/usr/lib64
/usr/local/lib
/usr/local/lib64
)
if(WIN32)
get_filename_component(
ActiveTcl_CurrentVersion
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\ActiveState\\ActiveTcl;CurrentVersion]"
NAME)
set(TCLTK_POSSIBLE_LIB_PATHS ${TCLTK_POSSIBLE_LIB_PATHS}
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\ActiveState\\ActiveTcl\\${ActiveTcl_CurrentVersion}]/lib"
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\Scriptics\\Tcl\\8.6;Root]/lib"
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\Scriptics\\Tcl\\8.5;Root]/lib"
"$ENV{ProgramFiles}/Tcl/Lib"
"C:/Program Files/Tcl/lib"
"C:/Tcl/lib"
)
endif()
find_library(TCL_LIBRARY
NAMES
tcl86 tcl8.6
tcl85 tcl8.5
tcl
tcl${TCL_VERSION} tcl${TCL_TCLSH_VERSION}
PATHS ${TCL_POSSIBLE_LIB_PATHS}
)
cmake_find_frameworks(Tcl)
set(TCL_FRAMEWORK_INCLUDES)
if(Tcl_FRAMEWORKS)
if(NOT TCL_INCLUDE_PATH)
foreach(dir ${Tcl_FRAMEWORKS})
set(TCL_FRAMEWORK_INCLUDES ${TCL_FRAMEWORK_INCLUDES} ${dir}/Headers)
endforeach(dir)
endif()
endif()
set(TCL_POSSIBLE_INCLUDE_PATHS
"${TCL_LIBRARY_PATH_PARENT}/include"
"${TCL_INCLUDE_PATH}"
${TCL_FRAMEWORK_INCLUDES}
"${TCL_TCLSH_PATH_PARENT}/include"
/usr/include/tcl8.6
/usr/include/tcl8.5
/usr/include
/usr/local/include
/usr/include/tcl${TCL_VERSION}
/usr/local/include/tcl${TCL_VERSION}
/usr/local/include/tcl8.6
/usr/local/include/tcl8.5
)
if(WIN32)
set(TCLTK_POSSIBLE_INCLUDE_PATHS ${TCLTK_POSSIBLE_INCLUDE_PATHS}
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\ActiveState\\ActiveTcl\\${ActiveTcl_CurrentVersion}]/include"
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\Scriptics\\Tcl\\8.6;Root]/include"
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\Scriptics\\Tcl\\8.5;Root]/include"
"$ENV{ProgramFiles}/Tcl/include"
"C:/Program Files/Tcl/include"
"C:/Tcl/include"
)
endif()
find_path(TCL_INCLUDE_PATH
NAMES tcl.h
PATHS ${TCL_POSSIBLE_INCLUDE_PATHS}
)
if(TCL_LIBRARY AND TCL_INCLUDE_PATH)
set(TCL_VERSION ${TCL_VERSION})
set(TCL_LIBARY ${TCL_LIBRARY})
set(TCL_INCLUDE_PATH ${TCL_INCLUDE_PATH})
set(TCL_FOUND TRUE)
endif()
mark_as_advanced(
TCL_INCLUDE_PATH
TCL_LIBRARY
TCL_VERSION
)
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2015-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2015-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+1 -1
View File
@@ -41,7 +41,7 @@ find_library(ZLIB_LIBRARY
${ZLIB_NAMES}
PATHS
"[HKEY_LOCAL_MACHINE\\SOFTWARE\\GnuWin32\\Zlib;InstallPath]/lib"
)
)
mark_as_advanced(ZLIB_LIBRARY ZLIB_INCLUDE_DIR)
if(ZLIB_INCLUDE_DIR AND EXISTS "${ZLIB_INCLUDE_DIR}/zlib.h")
+2 -2
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
@@ -37,4 +37,4 @@ foreach(file ${files})
else()
message(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.")
endif()
endforeach(file)
endforeach()
+38 -17
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2005 Benoit Papillault <benoit.papillault@free.fr>
# Copyright (C) 2005-2006 Julien Louis <ptitlouis@sysif.net>
# Copyright (C) 2005-2009 Emmanuel Bouthenot <kolter@openics.org>
@@ -47,10 +47,12 @@ AC_CONFIG_FILES([weechat-${VERSION}-1.cygport:weechat.cygport.in])
case "$host_os" in
freebsd* | openbsd*)
CFLAGS="$CFLAGS -I/usr/local/include"
CXXFLAGS="$CXXFLAGS -I/usr/local/include"
LDFLAGS="$LDFLAGS -L/usr/local/lib"
;;
netbsd*)
CFLAGS="$CFLAGS -I/usr/pkg/include"
CXXFLAGS="$CXXFLAGS -I/usr/pkg/include"
LDFLAGS="$LDFLAGS -L/usr/pkg/lib"
;;
solaris*)
@@ -477,7 +479,10 @@ if test "x$enable_python" = "xyes" ; then
if test "x$enable_python2" = "xyes" ; then
PKG_CHECK_MODULES(PYTHON, [python2], [PYTHON_FOUND=yes; PYTHON_VERSION=`$PKGCONFIG --modversion python2`], [PYTHON_FOUND=no])
else
PKG_CHECK_MODULES(PYTHON, [python3], [PYTHON_FOUND=yes; PYTHON_VERSION=`$PKGCONFIG --modversion python3`], [PYTHON_FOUND=no])
PKG_CHECK_MODULES(PYTHON, [python3-embed], [PYTHON_FOUND=yes; PYTHON_VERSION=`$PKGCONFIG --modversion python3-embed`], [PYTHON_FOUND=no])
if test "x$PYTHON_FOUND" != "xyes"; then
PKG_CHECK_MODULES(PYTHON, [python3], [PYTHON_FOUND=yes; PYTHON_VERSION=`$PKGCONFIG --modversion python3`], [PYTHON_FOUND=no])
fi
fi
if test "x$PYTHON_FOUND" != "xyes" ; then
AC_MSG_WARN([
@@ -505,7 +510,7 @@ RUBY_VERSION=
if test "x$enable_ruby" = "xyes" ; then
RUBY_CFLAGS=""
RUBY_LFLAGS=""
for v in "2.6" "2.5" "2.4" "2.3" "2.2" "2.1" "2.0" "1.9" "1.8" ; do
for v in "2.7" "2.6" "2.5" "2.4" "2.3" "2.2" "2.1" "2.0" "1.9" "1.8" ; do
pkgconfig_ruby_found=`$PKGCONFIG --exists ruby-$v 2>/dev/null`
if test "x$?" = "x0" ; then
RUBY_VERSION=`$PKGCONFIG --modversion ruby-$v`
@@ -517,7 +522,7 @@ if test "x$enable_ruby" = "xyes" ; then
# detect old Ruby versions
if test "x$RUBY_CFLAGS" = "x" -o "x$RUBY_LFLAGS" = "x" ; then
AC_PATH_PROGS(RUBY, ruby1.9.3 ruby1.9.2 ruby1.9.1 ruby1.9 ruby1.8 ruby)
AC_PATH_PROGS(RUBY, ruby1.9.3 ruby1.9.2 ruby1.9.1 ruby1.9 ruby)
if test -z $RUBY ; then
AC_MSG_WARN([
*** Ruby must be installed on your system but ruby interpreter couldn't be found in path.
@@ -559,7 +564,7 @@ fi
LUA_VERSION=
if test "x$enable_lua" = "xyes" ; then
ac_save_CPPFLAGS="$CPPFLAGS"
ac_save_CXXFLAGS="$CXXFLAGS"
ac_save_CFLAGS="$CFLAGS"
ac_save_LDFLAGS="$LDFLAGS"
@@ -568,7 +573,7 @@ if test "x$enable_lua" = "xyes" ; then
if test -n "$lua_inc"; then
CFLAGS="$CFLAGS -I$lua_inc"
CPPFLAGS="$CPPFLAGS -I$lua_inc"
CXXFLAGS="$CXXFLAGS -I$lua_inc"
fi
if test -n "$lua_lib"; then
LDFLAGS="$LDFLAGS -L$lua_lib"
@@ -665,7 +670,7 @@ if test "x$enable_lua" = "xyes" ; then
fi
CFLAGS="$ac_save_CFLAGS"
CPPFLAGS="$ac_save_CPPFLAGS"
CXXFLAGS="$ac_save_CXXFLAGS"
LDFLAGS="$ac_save_LDFLAGS"
else
not_asked="$not_asked lua"
@@ -727,7 +732,7 @@ if test "x$enable_guile" = "xyes" ; then
guile_found="no"
AC_MSG_CHECKING(for Guile headers and libraries)
echo
for v in "2.0" ; do
for v in "3.0" "2.2" "2.0" ; do
pkgconfig_guile_found=`$PKGCONFIG --exists guile-$v 2>/dev/null`
if test "x$?" = "x0" ; then
GUILE_VERSION=`$PKGCONFIG --modversion guile-$v`
@@ -831,7 +836,7 @@ AC_LANG_POP
PHP_VERSION=
if test "x$enable_php" = "xyes" ; then
ac_save_CPPFLAGS="$CPPFLAGS"
ac_save_CXXFLAGS="$CXXFLAGS"
ac_save_CFLAGS="$CFLAGS"
ac_save_LDFLAGS="$LDFLAGS"
@@ -840,7 +845,7 @@ if test "x$enable_php" = "xyes" ; then
if test -n "$php_inc"; then
CFLAGS="$CFLAGS -I$php_inc"
CPPFLAGS="$CPPFLAGS -I$php_inc"
CXXFLAGS="$CXXFLAGS -I$php_inc"
fi
if test -n "$php_lib"; then
LDFLAGS="$LDFLAGS -L$php_lib"
@@ -849,7 +854,7 @@ if test "x$enable_php" = "xyes" ; then
if test "x$PHP_CFLAGS" = "x" -o "x$PHP_LFLAGS" = "x" ; then
AC_MSG_CHECKING(for PHP headers and libraries with pkg-config)
echo
for l in "7.3" "73" "7.2" "72" "7.1" "71" "7.0" "70" "7" "$php_suffix" "" ; do
for l in "7.4" "74" "7.3" "73" "7.2" "72" "7.1" "71" "7.0" "70" "7" "$php_suffix" "" ; do
pkgconfig_php_found=`$PKGCONFIG --exists php$l 2>/dev/null`
if test "x$?" = "x0" ; then
pkgconfig_php_found=`$PKGCONFIG --atleast-version=7 php$l 2>/dev/null`
@@ -866,7 +871,7 @@ if test "x$enable_php" = "xyes" ; then
if test "x$PHP_CFLAGS" = "x" -o "x$PHP_LFLAGS" = "x" ; then
PHPCONFIG=""
AC_MSG_CHECKING(for PHP headers and libraries with php-config)
for l in "7.3" "73" "7.2" "72" "7.1" "71" "7.0" "70" "7" "$php_suffix" "" ; do
for l in "7.4" "74" "7.3" "73" "7.2" "72" "7.1" "71" "7.0" "70" "7" "$php_suffix" "" ; do
AC_CHECK_PROG(PHPCONFIG, "php-config$l", "php-config$l")
if test "x$PHPCONFIG" != "x" ; then
php_config_version=`$PHPCONFIG --version`
@@ -887,7 +892,7 @@ if test "x$enable_php" = "xyes" ; then
if test "x$ac_found_php_header" = "xyes" ; then
PHP_CFLAGS="$CFLAGS"
fi
for l in "7.3" "73" "7.2" "72" "7.1" "71" "7.0" "70" "7" "$php_suffix" "" ; do
for l in "7.4" "74" "7.3" "73" "7.2" "72" "7.1" "71" "7.0" "70" "7" "$php_suffix" "" ; do
AC_CHECK_LIB(php$l,php_execute_script,ac_found_php_lib="yes",ac_found_php_lib="no")
if test "x$ac_found_php_lib" = "xyes" ; then
PHP_VERSION=">=7.0.0"
@@ -922,7 +927,7 @@ if test "x$enable_php" = "xyes" ; then
fi
CFLAGS="$ac_save_CFLAGS"
CPPFLAGS="$ac_save_CPPFLAGS"
CXXFLAGS="$ac_save_CXXFLAGS"
LDFLAGS="$ac_save_LDFLAGS"
else
not_asked="$not_asked php"
@@ -1106,6 +1111,7 @@ fi
if test "x$enable_largefile" = "xyes" ; then
CFLAGS="$CFLAGS -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_LARGE_FILES"
CXXFLAGS="$CXXFLAGS -D_FILE_OFFSET_BITS=64 -D_LARGEFILE64_SOURCE -D_LARGEFILE_SOURCE -D_LARGE_FILES"
else
not_asked="$not_asked largefile"
fi
@@ -1285,10 +1291,13 @@ weechat_libdir=${libdir}/weechat
AC_SUBST(weechat_libdir)
COMMON_CFLAGS="-fsigned-char -Wall -Wextra -Werror-implicit-function-declaration"
COMMON_CXXFLAGS="-fsigned-char -Wall -Wextra"
AC_MSG_CHECKING([whether we have GNU assembler])
GAS=`as --version < /dev/null 2>/dev/null | grep GNU`
if test "$GAS"; then
COMMON_CFLAGS="${COMMON_CFLAGS} -pipe"
COMMON_CXXFLAGS="${COMMON_CXXFLAGS} -pipe"
AC_MSG_RESULT(yes)
else
AC_MSG_RESULT(no)
@@ -1298,10 +1307,18 @@ CFLAGS=`echo $CFLAGS | sed 's/ -g / /g'`
CFLAGS=`echo $CFLAGS | sed 's/^-g //g'`
CFLAGS=`echo $CFLAGS | sed 's/ -g$//g'`
CFLAGS=`echo $CFLAGS | sed 's/^-g$//g'`
CXXFLAGS=`echo $CXXFLAGS | sed 's/ -g / /g'`
CXXFLAGS=`echo $CXXFLAGS | sed 's/^-g //g'`
CXXFLAGS=`echo $CXXFLAGS | sed 's/ -g$//g'`
CXXFLAGS=`echo $CXXFLAGS | sed 's/^-g$//g'`
if test "x$debug" = "x0" ; then
CFLAGS="$COMMON_CFLAGS $CFLAGS"
CXXFLAGS="$COMMON_CXXFLAGS $CXXFLAGS"
else
CFLAGS="$COMMON_CFLAGS $CFLAGS -g -O0"
CXXFLAGS="$COMMON_CXXFLAGS $CXXFLAGS -g -O0"
fi
LIBS="$LIBS $INTLLIBS"
@@ -1311,7 +1328,7 @@ freebsd*)
if test "x$enable_perl" = "xyes" -o "x$enable_python" = "xyes" ; then
CFLAGS="$CFLAGS -pthread"
fi
CFLAGS="$CFLAGS $CPPFLAGS"
CFLAGS="$CFLAGS $CXXFLAGS"
;;
openbsd*)
if test "x$enable_python" = "xyes" ; then
@@ -1322,17 +1339,20 @@ netbsd*)
if test "x$enable_perl" = "xyes" -o "x$enable_python" = "xyes" ; then
CFLAGS="$CFLAGS -pthread"
fi
CFLAGS="$CFLAGS $CPPFLAGS"
CFLAGS="$CFLAGS $CXXFLAGS"
;;
gnu*)
LDFLAGS="$LDFLAGS -lpthread"
;;
haiku*)
LDFLAGS="$LDFLAGS -lnetwork"
;;
*)
;;
esac
CFLAGS="$CFLAGS -DWEECHAT_VERSION=\\\"$VERSION\\\" -DWEECHAT_LICENSE=\\\"$LICENSE\\\""
CPPFLAGS="$CPPFLAGS -DWEECHAT_VERSION=\\\"$VERSION\\\" -DWEECHAT_LICENSE=\\\"$LICENSE\\\""
CXXFLAGS="$CXXFLAGS -DWEECHAT_VERSION=\\\"$VERSION\\\" -DWEECHAT_LICENSE=\\\"$LICENSE\\\""
# ------------------------------------------------------------------------------
# output Makefiles
@@ -1369,6 +1389,7 @@ AM_CONDITIONAL(MAN, test "$enable_man" = "yes")
AM_CONDITIONAL(DOC, test "$enable_doc" = "yes")
AC_OUTPUT([Makefile
icons/Makefile
doc/Makefile
doc/en/Makefile
doc/fr/Makefile
+2 -2
View File
@@ -13,7 +13,7 @@ Build-Depends:
libaspell-dev,
liblua5.3-dev,
tcl8.6-dev,
guile-2.0-dev,
guile-2.2-dev,
libv8-dev [amd64 i386 armel armhf mips mipsel hurd-i386 kfreebsd-amd64 kfreebsd-i386],
php-dev, libphp-embed, libargon2-0-dev, libsodium-dev,
libxml2-dev,
@@ -21,7 +21,7 @@ Build-Depends:
libgcrypt20-dev,
libgnutls28-dev,
zlib1g-dev
Standards-Version: 4.3.0
Standards-Version: 4.4.0
Homepage: https://weechat.org/
Vcs-Git: https://salsa.debian.org/kolter/weechat.git
Vcs-Browser: https://salsa.debian.org/kolter/weechat
+1 -1
View File
@@ -26,7 +26,7 @@ weechat (0.3.1-1) unstable; urgency=low
are stronger checks while connecting with SSL. By default, if a connection
is not fully trusted it will fail.
You can find more information on how to handle this new behaviour here:
https://weechat.org/blog/post/2009/12/01/SSL-certificates
https://blog.weechat.org/post/2009/12/01/SSL-certificates
-- Emmanuel Bouthenot <kolter@debian.org> Mon, 25 Jan 2010 12:35:11 +0100
+15
View File
@@ -1,3 +1,18 @@
weechat (2.6-2) unstable; urgency=medium
* Add a patch from upstream to support Guile 2.2 (Closes: #885235)
-- Emmanuel Bouthenot <kolter@debian.org> Fri, 11 Oct 2019 15:07:22 +0000
weechat (2.6-1) unstable; urgency=medium
* New upstream release
* Build only with Python3 (Closes: #938817)
* Bump Standards-Version to 4.4.0
* Build Lua plugin against Lua 5.3
-- Emmanuel Bouthenot <kolter@debian.org> Tue, 17 Sep 2019 13:30:32 +0000
weechat (2.4-1) unstable; urgency=medium
* New upstream release
+2 -2
View File
@@ -13,7 +13,7 @@ Build-Depends:
libaspell-dev,
liblua5.3-dev,
tcl8.6-dev,
guile-2.0-dev,
guile-2.2-dev,
libv8-dev [amd64 i386 armel armhf mips mipsel hurd-i386 kfreebsd-amd64 kfreebsd-i386],
php-dev, libphp-embed, libargon2-0-dev, libsodium-dev,
libxml2-dev,
@@ -21,7 +21,7 @@ Build-Depends:
libgcrypt20-dev,
libgnutls28-dev,
zlib1g-dev
Standards-Version: 4.3.0
Standards-Version: 4.4.0
Homepage: https://weechat.org/
Vcs-Git: https://salsa.debian.org/kolter/weechat.git
Vcs-Browser: https://salsa.debian.org/kolter/weechat
+1 -1
View File
@@ -4,7 +4,7 @@ Upstream-Contact: Sébastien Helleu <flashcode@flashtux.org>
Source: https://weechat.org/
Files: *
Copyright: 2003-2019, Sébastien Helleu <flashcode@flashtux.org>
Copyright: 2003-2020, Sébastien Helleu <flashcode@flashtux.org>
License: GPL-3+
Files: src/core/wee-command.c
+3 -7
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2009 Emmanuel Bouthenot <kolter@openics.org>
#
# This file is part of WeeChat, the extensible chat client.
@@ -19,13 +19,9 @@
#
if(ENABLE_MAN OR ENABLE_DOC)
find_package(Asciidoctor)
if(ASCIIDOCTOR_FOUND)
set(ASCIIDOCTOR_ARGS -a experimental -a icons=font -a revnumber="${VERSION}" -a sectanchors -a source-highlighter=prettify)
add_subdirectory(cs)
add_subdirectory(de)
add_subdirectory(en)
@@ -35,7 +31,7 @@ if(ENABLE_MAN OR ENABLE_DOC)
add_subdirectory(ja)
add_subdirectory(pl)
add_subdirectory(ru)
else()
message(SEND_ERROR "Asciidoctor not found")
endif()
endif()
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2006 Julien Louis <ptitlouis@sysif.net>
#
# This file is part of WeeChat, the extensible chat client.
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+1 -1
View File
@@ -1,7 +1,7 @@
WeeChat je napsán Sébastienem Helleu a přispěvovateli (kompletní seznam je v
souboru AUTHORS.adoc).
Copyright (C) 2003-2019 {author}
Copyright (C) 2003-2020 {author}
WeeChat is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
+5 -1
View File
@@ -235,12 +235,16 @@ název volby):
----
[[connect_to_irc_server]]
== Připojení k IRC serveru a automatické ořipojení kanálů
== Připojení k IRC serveru
----
/connect freenode
----
// TRANSLATION MISSING
With this command, WeeChat connects to the freenode server and auto-joins the
channels configured in the "autojoin" server option.
// TRANSLATION MISSING
[NOTE]
Tento příkaz může být použit k vytvoření nového připojení k serveru bez
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2006 Julien Louis <ptitlouis@sysif.net>
#
# This file is part of WeeChat, the extensible chat client.
+3 -1
View File
@@ -38,6 +38,8 @@
| irc | irc_privates | Private auf allen IRC Servern
| irc | irc_raw_filters | Filter für IRC Rohbuffer
| irc | irc_server | aktueller IRC-Server
| irc | irc_server_channels | Channels des derzeitigen IRC-Server
@@ -142,7 +144,7 @@
| weechat | env_vars | Umgebungsvariablen
| weechat | filename | Dateinamen
| weechat | filename | Dateiname; optionales Argument: default path (Hinweis: Inhalt wird evaluiert, siehe /help eval)
| weechat | filters_names | Liste der Filter
+2
View File
@@ -213,6 +213,7 @@ _last_irc_server_ +
| _name_   (string) +
_options_   (pointer) +
_temp_server_   (integer) +
_fake_server_   (integer) +
_reloading_from_config_   (integer) +
_reloaded_from_config_   (integer) +
_addresses_eval_   (string) +
@@ -546,6 +547,7 @@ _layout_number_   (integer) +
_layout_number_merge_order_   (integer) +
_name_   (string) +
_full_name_   (string) +
_old_full_name_   (string) +
_short_name_   (string) +
_type_   (integer) +
_notify_   (integer) +
+5 -1
View File
@@ -80,11 +80,13 @@
| tcl | tcl_version | Version des verwendeten Interpreters | -
| weechat | auto_connect | 1, falls die automatische Verbindung zu Servern aktiviert ist, 0, wenn sie vom Benutzer deaktiviert wurde (Option "-a" oder "--no-connect") | -
| weechat | charset_internal | Interner WeeChat Zeichensatz | -
| weechat | charset_terminal | Terminal Zeichensatz | -
| weechat | color_ansi_regex | erweiterte reguläre POSIX Ausdrücke um ANSI Escapesequenz zu suchen | -
| weechat | color_ansi_regex | Erweiterte reguläre POSIX Ausdrücke um ANSI Escapesequenz zu suchen | -
| weechat | color_rgb2term | RGB Farbe wurde umgewandelt in Terminalfarbe (0-255) | RGB,limit (Obergrenze ist optional und ist Standardmäßig 256)
@@ -130,6 +132,8 @@
| weechat | weechat_dir | WeeChat Verzeichnis | -
| weechat | weechat_headless | 1, falls WeeChat im Hintergrundmodus ausgeführt wird | -
| weechat | weechat_libdir | WeeChat "lib" Verzeichnis | -
| weechat | weechat_localedir | "lokales" Verzeichnis von WeeChat | -
@@ -6,7 +6,7 @@
|===
| Erweiterung | Name | Beschreibung | Hashtable (Eingabe) | Hashtable (Ausgabe)
| irc | irc_message_parse | Parse eine IRC Nachricht | "message": IRC Nachricht, "server": Servername (optional) | "tags": Tags, "message_without_tags": Nachrichten ohne Tags, "nick": Nick, "host": Host, "command": Befehl, "channel": Channel, "arguments": Argumente (schließt Channel ein), "text": Text (zum Beispiel eine Nachricht von einem User), "pos_command": Index der "command" Nachricht ("-1" falls "command" nicht gefunden wird), "pos_arguments": Index der "arguments" Nachricht ("-1" falls "arguments" nicht gefunden wird), "pos_channel": Index der "channel" Nachricht ("-1" falls "channel" nicht gefunden wird),"pos_text": Index für "text" Nachricht ("-1" falls "text" nicht gefunden wird)
| irc | irc_message_parse | Parse eine IRC Nachricht | "message": IRC Nachricht, "server": Servername (optional) | "tags": Tags, "message_without_tags": Nachrichten ohne Tags, "nick": Nick, "user": Benutzername, "host": Host, "command": Befehl, "channel": Channel, "arguments": Argumente (schließt Channel ein), "text": Text (zum Beispiel eine Nachricht von einem User), "pos_command": Index der "command" Nachricht ("-1" falls "command" nicht gefunden wird), "pos_arguments": Index der "arguments" Nachricht ("-1" falls "arguments" nicht gefunden wird), "pos_channel": Index der "channel" Nachricht ("-1" falls "channel" nicht gefunden wird),"pos_text": Index für "text" Nachricht ("-1" falls "text" nicht gefunden wird)
| irc | irc_message_split | trennt eine IRC Nachricht (standardmäßig in 512 Bytes große Nachrichten) | "message": IRC Nachricht, "server": Servername (optional) | "msg1" ... "msgN": Nachrichten die versendet werden sollen (ohne abschließendes "\r\n"), "args1" ... "argsN": Argumente für Nachrichten, "count": Anzahl der Nachrichten
@@ -20,6 +20,9 @@ Jede Zeile die einen Buffer anzeigt wird mittels Zeichenketten-Evaluation darges
Die folgenden Variablen können in den obigen Optionen genutzt werden:
- bar item data (siehe hdata "bar_item" in API Dokumentation für eine vollständige Liste), zum Beispiel:
- ${bar_item.name}
- window data, wo das Bar-Item dargestellt werden soll (in "root" Bars existieren keine Fenster, siehe hdata "window" in API Dokumentation für eine vollständige Liste), zum Beispiel:
- ${window.number}
- ${window.buffer.full_name}
- buffer data (siehe hdata "buffer" in API Dokumentation für eine vollständige Liste), zum Beispiel:
- ${buffer.number}
- ${buffer.name}
+2 -2
View File
@@ -117,7 +117,7 @@ Tasten und Eingaben um Optionen im fset Buffer zu editieren:
alt+enter s Wert setzen
alt+f, alt+n n ein neuer Wert wird gesetzt, der alte Wert wird gelöscht
alt+f, alt+a a dem Wert was hinzufügen
alt+',' , markieren/demarkieren einer Option
alt+',' , markieren/demarkieren einer Option
shift+hoch eine Zeile nach oben und markiert/demarkiert Option
shift+runter markiert/demarkiert Option und geht eine Zeile nach unten
m:xxx markiert Optionen welche angezeigt werden und auf die der Filter "xxx" zutrifft (jeder Filter für Option oder Wert ist erlaubt, siehe Filterung weiter oben)
@@ -127,7 +127,7 @@ weitere Tasten und Eingaben im fset Buffer:
ctrl+L der Bildschirm wird neu gezeichnet (Befehl: /fset -refresh)
$ Optionen neu einlesen (markierte Optionen werden beibehalten)
$$ Optionen neu einlesen (Markierungen von Optionen werden dabei gelöscht)
alt+p p umschalten zwischen Beschreibung von Erweiterungen (plugins.desc.*)
alt+p p Umschalten der Beschreibung von Erweiterungen (plugins.desc.*)
alt+v v Hilfe-Bar Ein-/Ausschalten
s:x,y sortiert Optionen nach Bereichen x,y (siehe /help fset.look.sort)
s: setzt Sortierung wieder auf Standardwerte (siehe /help fset.look.sort)
+18 -7
View File
@@ -243,10 +243,10 @@ target: Servername
----
/disconnect [<server>|-all|-pending [<reason>]]
server: interner Name des Servers
-all: Verbindung zu allen Servern trennen
-pending: bricht eine automatische Wiederverbindung für Server ab, zu denen gerade eine erneute Verbindung aufgebaut werden soll
reason: Begründung der Trennung
server: interner Name des Servers
-all: Verbindung zu allen Servern trennen
-pending: bricht eine automatische Wiederverbindung zu Servern ab, zu denen gerade eine erneute Verbindung aufgebaut werden soll
reason: Begründung für die Trennung
----
[[command_irc_halfop]]
@@ -373,7 +373,7 @@ reason: Grund der Abmeldung
----
[[command_irc_links]]
* `+links+`: alle Servernamen auflisten die dem antwortenden Server bekannt sind
* `+links+`: alle Servernamen auflisten, die dem antwortenden Server bekannt sind
----
/links [[<target>] <server_mask>]
@@ -726,7 +726,8 @@ reason: Grund der Abmeldung
reorder <name> [<name>...]
open <name>|-all [<name>...]
del|keep <name>
deloutq|jump|raw
deloutq|jump
raw [<filter>]
list: listet Server auf (ohne Angabe von Argumente wird diese Liste standardmäßig ausgegeben)
listfull: listet alle Server auf, mit detaillierten Informationen zu jedem einzelnen Server
@@ -739,12 +740,19 @@ nooption: stellt die Boolean Einstellung auf 'off' (Beispiel: -nossl)
copy: erstellt eine Kopie des Servers
rename: benennt den Server um
reorder: Anordnung der Server ändern
open: öffnen den Serverbuffer, ohne eine Verbindung herzustellen
open: öffnet den Serverbuffer, ohne eine Verbindung herzustellen
keep: übernimmt den Server in die Konfigurationsdatei (nur sinnvoll bei temporär angelegten Servern)
del: entfernt einen Server
deloutq: löscht bei allen Servern alle ausgehende Nachrichten, die in der Warteschlange stehen (dies betrifft alle Nachrichten die WeeChat gerade sendet)
jump: springt zum Server-Buffer
raw: öffnet Buffer mit Roh-IRC-Daten
filter: setzt einen neuen Filter um übereinstimmende Nachrichten anzuzeigen (ein Filter kann auch in der Eingabezeile im IRC Datenbuffer angelegt werden); erlaubte Formattierungen:
* zeigt alle Nachrichten an (keine Filterung von Nachrichten)
xxx zeigt nur Nachrichten mit "xxx" an
s:xxx zeigt nur Nachrichten von Server "xxx" an
f:xxx zeigt nur Nachrichten mit dem entsprechenden Flag an: recv (erhaltene Nachricht), sent (gesendete Nachricht), modified (Nachricht welche modifiziert wurde), redirected (umgeleitete Nachricht)
m:xxx zeigt nur IRC Befehl "xxx" an
c:xxx zeigt nur Nachrichten an auf die die evaluierte Bedingung "xxx" zutrifft, folgende Variable können verwendet werden: Ausgabe der Funktion irc_message_parse (wie nick, command, channel, text, etc., siehe Funktion info_get_hashtable in der Anleitung für API Erweiterung für eine Liste aller möglichen Variablen), date (Format: "yyyy-mm-dd hh:mm:ss"), server, recv, sent, modified, redirected
Beispiele:
/server listfull
@@ -756,6 +764,9 @@ Beispiele:
/server reorder freenode2 freenode
/server del freenode
/server deloutq
/server raw
/server raw s:freenode
/server raw c:${recv} && ${command}==PRIVMSG && ${nick}==foo
----
[[command_irc_service]]
+31 -7
View File
@@ -44,6 +44,12 @@
** Werte: ein Farbname für WeeChat (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), eine Terminal-Farbnummer oder ein Alias; Attribute können vor eine Farbe gesetzt werden (gilt ausschließlich für die Textfarbe und nicht für den Hintergrund): "*" für fett, "!" für invertiert, "/" für kursiv, "_" für unterstrichen
** Standardwert: `+green+`
* [[option_irc.color.message_kick]] *irc.color.message_kick*
** Beschreibung: pass:none[Textfarbe in der die Meldungen für kick/kill Nachrichten angezeigt werden soll]
** Typ: Farbe
** Werte: ein Farbname für WeeChat (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), eine Terminal-Farbnummer oder ein Alias; Attribute können vor eine Farbe gesetzt werden (gilt ausschließlich für die Textfarbe und nicht für den Hintergrund): "*" für fett, "!" für invertiert, "/" für kursiv, "_" für unterstrichen
** Standardwert: `+red+`
* [[option_irc.color.message_quit]] *irc.color.message_quit*
** Beschreibung: pass:none[Textfarbe in der die Meldungen für das Verlassen/Beenden eines Channels angezeigt werden soll]
** Typ: Farbe
@@ -68,6 +74,12 @@
** Werte: ein Farbname für WeeChat (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), eine Terminal-Farbnummer oder ein Alias; Attribute können vor eine Farbe gesetzt werden (gilt ausschließlich für die Textfarbe und nicht für den Hintergrund): "*" für fett, "!" für invertiert, "/" für kursiv, "_" für unterstrichen
** Standardwert: `+green+`
* [[option_irc.color.reason_kick]] *irc.color.reason_kick*
** Beschreibung: pass:none[Textfarbe in der die Begründung einer kick/kill Nachricht angezeigt werden soll]
** Typ: Farbe
** Werte: ein Farbname für WeeChat (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), eine Terminal-Farbnummer oder ein Alias; Attribute können vor eine Farbe gesetzt werden (gilt ausschließlich für die Textfarbe und nicht für den Hintergrund): "*" für fett, "!" für invertiert, "/" für kursiv, "_" für unterstrichen
** Standardwert: `+default+`
* [[option_irc.color.reason_quit]] *irc.color.reason_quit*
** Beschreibung: pass:none[Textfarbe in der die Begründung einer part/quit Nachricht angezeigt werden soll]
** Typ: Farbe
@@ -212,6 +224,12 @@
** Werte: on, off
** Standardwert: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** Beschreibung: pass:none[zeigt eine Warnung in einem privaten Buffer an, sobald sich die Adresse eines Remote-Nick geändert hat; diese Option ist standardmäßig ausgeschaltet, da Server wie bitlbee eine solche Warnung unvermittelt auslösen (die Adresse des Remote-Nick ändert sich während eines Login mehrfach)]
** Typ: boolesch
** Werte: on, off
** Standardwert: `+off+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** Beschreibung: pass:none[durch Kommata getrennte Liste von Wörtern die in Channel-Buffern als Highlight erscheinen sollen (zwischen Groß- und Kleinschreibung wird nicht unterschieden. Um zwischen Groß- und Kleinschreibung zu unterscheiden muss zu Beginn "(?-i)" genutzt werden; des Weiteren können folgende Variablen genutzt werden: $nick, $channel und $server). Wird ein Buffer geöffnet, dann werden die angegeben Wörter dem Buffer-Merkmal "highlight_words" hinzugefügt. Dies bedeutet, dass diese Einstellung keinen direkten Einfluss auf schon geöffnete Buffer hat. Eine leere Zeichenkette deaktiviert ein Highlight für den Nick. Beispiel: "$nick", "(?-i)$nick"]
** Typ: Zeichenkette
@@ -369,7 +387,7 @@
** Standardwert: `+merge_with_core+`
* [[option_irc.look.smart_filter]] *irc.look.smart_filter*
** Beschreibung: pass:none[filtert join/part/quit/nick Nachrichten für einen Nick der einige Minuten im Channel inaktiv gewesen ist. Dazu muss ein Filter mit dem Schlagwort "irc_smart_filter" erstellt werden]
** Beschreibung: pass:none[filtert join/part/quit/nick Nachrichten für einen Nick der einige Minuten im Channel inaktiv gewesen ist (dazu muss ein Filter mit dem Schlagwort "irc_smart_filter" erstellt werden, siehe /help filter)]
** Typ: boolesch
** Werte: on, off
** Standardwert: `+on+`
@@ -446,12 +464,6 @@
** Werte: beliebige Zeichenkette
** Standardwert: `+"*!$ident@$host"+`
* [[option_irc.network.channel_encode]] *irc.network.channel_encode*
** Beschreibung: pass:none[dekodieren/kodieren von Channelnamen innerhalb einer Nachricht mittels Charset-Optionen; es wird empfohlen diese Option deaktiviert zu lassen sofern man ausschließlich UTF-8 in Channelnamen verwendet. Diese Option sollte nur dann verwendet werden, sofern man exotische Zeichensätze wie ISO für Channelnamen nutzt]
** Typ: boolesch
** Werte: on, off
** Standardwert: `+off+`
* [[option_irc.network.colors_receive]] *irc.network.colors_receive*
** Beschreibung: pass:none[wenn deaktiviert, werden Farben-Codes von eingehenden Nachrichten ignoriert]
** Typ: boolesch
@@ -596,6 +608,12 @@
** Werte: beliebige Zeichenkette
** Standardwert: `+""+`
* [[option_irc.server_default.charset_message]] *irc.server_default.charset_message*
** Beschreibung: pass:none[Teil der IRC Nachricht (empfangen oder gesendet) die zum Zielzeichensatz dekodiert/kodiert werden soll; message = die komplette IRC Nachricht (Standard), channel = beginnend mit dem Channel-Namen (sofern dieser gefunden wird, ansonsten Fallback auf text), text = beginnend mit dem Nachrichtentext (dieser Wert sollte ausprobiert werden, falls es Probleme bei der Kodierung des Channel-Namen geben sollte)]
** Typ: integer
** Werte: message, channel, text
** Standardwert: `+message+`
* [[option_irc.server_default.command]] *irc.server_default.command*
** Beschreibung: pass:none[Befehl(e) welche nach einem Verbindungsaufbau zum Server und vor dem automatischem Betreten von Channels ausgeführt werden sollen (mehrere Befehle müssen durch ";" getrennt werden, soll ein Semikolon genutzt werden, schreibt man "\;", die Platzhalter $nick,$channel und $server werden durch den entsprechenden Wert ersetzt) (Hinweis: Inhalt wird evaluiert, siehe /help eval; Serveroptionen sind mittels ${irc_server.xxx} evaluiert und ${server} wird durch den eigentlichen Servernamen ersetzt)]
** Typ: Zeichenkette
@@ -746,6 +764,12 @@
** Werte: beliebige Zeichenkette
** Standardwert: `+""+`
* [[option_irc.server_default.ssl_password]] *irc.server_default.ssl_password*
** Beschreibung: pass:none[Passwort für SSL Zertifikat des privaten Schlüssels, nur unter gnutls Version >= 3.1.0 (Hinweis: Inhalt wird evaluiert, siehe /help eval; Serveroptionen sind mittels ${irc_server.xxx} evaluiert und ${server} wird durch den eigentlichen Servernamen ersetzt)]
** Typ: Zeichenkette
** Werte: beliebige Zeichenkette
** Standardwert: `+""+`
* [[option_irc.server_default.ssl_priorities]] *irc.server_default.ssl_priorities*
** Beschreibung: pass:none[Zeichenkette mit Prioritäten für gnutls (für die korrekte Syntax siehe gnutls Dokumentation unter Funktion gnutls_priority_init. Gebräuchliche Zeichenketten sind: "PERFORMANCE", "NORMAL", "SECURE128", "SECURE256", "EXPORT", "NONE")]
** Typ: Zeichenkette
+7 -1
View File
@@ -9,7 +9,7 @@
** Standardwert: `+default+`
* [[option_logger.color.backlog_line]] *logger.color.backlog_line*
** Beschreibung: pass:none[Textfarbe in der der Verlaufsspeicher dargestellt werden soll]
** Beschreibung: pass:none[Farbe der Zeilen des Verlaufspeichers; wird nur dann angewandt, wenn die Option logger.file.color_lines = off ist]
** Typ: Farbe
** Werte: ein Farbname für WeeChat (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), eine Terminal-Farbnummer oder ein Alias; Attribute können vor eine Farbe gesetzt werden (gilt ausschließlich für die Textfarbe und nicht für den Hintergrund): "*" für fett, "!" für invertiert, "/" für kursiv, "_" für unterstrichen
** Standardwert: `+default+`
@@ -20,6 +20,12 @@
** Werte: on, off
** Standardwert: `+on+`
* [[option_logger.file.color_lines]] *logger.file.color_lines*
** Beschreibung: pass:none[Nutze ANSI-Farbcodes für die in Logdateien geschriebenen Zeilen und zeige die Zeilen aus dem Verlaufspeicher in diesen Farben an]
** Typ: boolesch
** Werte: on, off
** Standardwert: `+off+`
* [[option_logger.file.flush_delay]] *logger.file.flush_delay*
** Beschreibung: pass:none[Zeit, in Sekunden, die verstreicht bis eine Protokolldatei gesichert wird (0 = Protokolldatei wird unmittelbar gesichert, nachdem eine neue Zeile dargestellt wurde)]
** Typ: integer
+3 -3
View File
@@ -111,7 +111,7 @@
** Standardwert: `+off+`
* [[option_relay.network.allowed_ips]] *relay.network.allowed_ips*
** Beschreibung: pass:none[erweiterter regulärer POSIX Ausdruck für IPs die von relay akzeptiert werden (Groß- und Kleinschreibung wird ignoriert. Um zwischen Groß- und Kleinschreibung zu unterscheiden muss die Zeichenkette mit "(?-i)" eingeleitet werden), Beispiele: "^(123\.45\.67\.89|192\.160\..*)$"]
** Beschreibung: pass:none[Erweiterter regulärer POSIX Ausdruck für IPs die von relay akzeptiert werden (Groß- und Kleinschreibung wird ignoriert. Um zwischen Groß- und Kleinschreibung zu unterscheiden muss die Zeichenkette mit "(?-i)" eingeleitet werden), Beispiele: "^(123\.45\.67\.89|192\.160\..*)$"]
** Typ: Zeichenkette
** Werte: beliebige Zeichenkette
** Standardwert: `+""+`
@@ -171,13 +171,13 @@
** Standardwert: `+""+`
* [[option_relay.network.totp_window]] *relay.network.totp_window*
** Beschreibung: pass:none[Anzahl der Time-based One-Time Passwörter die vor und nach dem aktuellen Passwort akzeptiert werden: 0 = nur das aktuelle Passwort wird akzeptiert, 1 = akzeptiert ein Passwort vorher, das aktuelle und ein Passwort danach, 2 = akzeptiert zwei Passwörter vorher, das aktuelle und zwei Passwörter danach, ...; umso höher die genutzte Zahl umso unsicherer das Verfahren (0 oder 1 sind empfohlene Werte)]
** Beschreibung: pass:none[Anzahl der Time-based One-Time Passwörter die vor und nach dem aktuellen Passwort akzeptiert werden: 0 = nur das aktuelle Passwort wird akzeptiert, 1 = akzeptiert ein Passwort vorher, das aktuelle und ein Passwort danach, 2 = akzeptiert zwei Passwörter vorher, das aktuelle und zwei Passwörter danach, ...; umso höher die genutzte Zahl umso unsicherer das Verfahren (0 oder 1 sind empfohlene Werte)]
** Typ: integer
** Werte: 0 .. 256
** Standardwert: `+0+`
* [[option_relay.network.websocket_allowed_origins]] *relay.network.websocket_allowed_origins*
** Beschreibung: pass:none[erweiterter regulärer POSIX Ausdruck für Origins in WebSockets (Groß- und Kleinschreibung wird ignoriert. Um Groß- und Kleinschreibung zu unterscheiden kann "(?-i)" vorangestellt werden), Beispiel: ^https?://(www\.)?example\.(com|org)"]
** Beschreibung: pass:none[Erweiterter regulärer POSIX Ausdruck für Origins in WebSockets (Groß- und Kleinschreibung wird ignoriert. Um Groß- und Kleinschreibung zu unterscheiden kann "(?-i)" vorangestellt werden), Beispiel: ^https?://(www\.)?example\.(com|org)"]
** Typ: Zeichenkette
** Werte: beliebige Zeichenkette
** Standardwert: `+""+`
+6 -4
View File
@@ -6,7 +6,7 @@
* `+script+`: WeeChat Skriptmanager
----
/script list [-o|-i]
/script list [-o|-ol|-i|-il]
search <text>
show <script>
load|unload|reload <script> [<script>...]
@@ -16,8 +16,10 @@
update
list: gibt alle geladenen Skripten im Buffer aus (unabhängig der Programmiersprache)
-o: gibt eine Liste der gestarteten Skripten im Buffer aus
-i: eine Liste der gestarteten Skripten wird in die Eingabezeile kopiert (um sie dann manuell in einen Buffer zu senden)
-o: gibt eine Liste der laufenden Skripten im Buffer aus (Ausgabe in englisch)
-ol: gibt eine Liste der laufenden Skripten im Buffer aus (Ausgabe ist übersetzt)
-i: eine Liste der laufenden Skripten wird in die Eingabezeile kopiert (um sie dann manuell in einen Buffer zu senden)(Ausgabe in englisch)
-il: eine Liste der laufenden Skripten wird in die Eingabezeile kopiert (um sie dann manuell in einen Buffer zu senden)(Ausgabe ist übersetzt)
search: sucht Skripten nach Schlagwörtern, Skriptsprache (python, perl, ...), Dateierweiterung (py, pl, ...) oder beliebigem Text. Das Ergebnis wird im Skripten-Buffer dargestellt
show: zeigt detailliert Informationen zu einem Skript an
load: startet Skript(en)
@@ -42,7 +44,7 @@ Im Skript-Buffer, werden folgende Statusangaben für ein Skript angezeigt:
| | | | | obsolete (neue Version verfügbar)
| | | | Skript wird ausgeführt (geladen)
| | | gehalten
| | Skript wird beim Start, von WeeChat, automatisch gestartet
| | Skript wird beim Start, von WeeChat, automatisch geladen
| Skript ist installiert (wird aber nicht ausgeführt)
es wird empfohlen dieses Skript zu installieren
+1 -1
View File
@@ -33,7 +33,7 @@ listdefault: zeigt die standardmäßig genutzten Trigger an
hsignal: Name(en) des hsignal (erforderlich)
modifier: Name(en) des modifier (erforderlich)
line: Buffertyp ("formatted", "free" oder "*"), Liste von Buffermasken, Tags
print: buffer, tags, message, strip colors
print: Buffer, Tags, Nachricht, Farben entfernen
command: Befehl (erforderlich), Beschreibung, Argumente, Beschreibung der Argumente, Vervollständigung
command_run: Befehl(e) (erforderlich)
timer: Intervall (erforderlich), Anpassung an Sekunden (erforderlich), maximale Anzahl an Aufrufen
+27 -21
View File
@@ -97,7 +97,7 @@ Beispiele:
unmerge: trennt Buffer wieder voneinander, falls zwei Buffer die selbe Nummer teilen
hide: versteckt einen Buffer
unhide: macht Buffer wieder sichtbar
renumber: Buffer werden um nummeriert (Einstellung weechat.look.buffer_auto_renumber muss deaktiviert sein)
renumber: Buffer werden umnummeriert (Einstellung weechat.look.buffer_auto_renumber muss deaktiviert sein)
close: Buffer schließen (Nummer oder Bereich ist optional)
notify: setzt den Status der Benachrichtigung für den aktuellen Buffer. Folgende Möglichkeiten bestimmen den Grad der Benachrichtigung und ob der Buffer in der Hotlist angezeigt wird:
none: keine Benachrichtigung
@@ -263,11 +263,12 @@ infolists: zeigt Information über die Infolists an
* `+eval+`: evaluierter Ausdruck
----
/eval [-n|-s] <expression>
[-n] -c <expression1> <operator> <expression2>
/eval [-n|-s] [-d] <expression>
[-n] [-d] -c <expression1> <operator> <expression2>
-n: gibt das Ergebnis aus, ohne das dieses in den Buffer gesendet wird (debug Modus)
-s: teilt Ausdrücke bevor sie evaluiert werden (mehrere Befehle können durch Semikolon getrennt werden)
-n: gibt das Ergebnis aus, ohne dass dieses in den Buffer gesendet wird (debug Modus)
-s: teilt Ausdrücke, bevor sie evaluiert werden (mehrere Befehle können durch Semikolon getrennt werden)
-d: eine Debug-Ausgabe nach Auswertung anzeigen
-c: Auswertung als Bedingung: nutzt Operatoren und runde Klammern, Rückgabewert als Boolean-Wert ("0" oder "1")
expression: Ausdruck welcher verarbeitet werden soll. Variablen im Format ${variable} werden ersetzt (siehe unten); mehrere Befehle werden durch ein Semikolon voneinander getrennt
operator: ein logischer oder vergleichender Operand:
@@ -287,7 +288,7 @@ expression: Ausdruck welcher verarbeitet werden soll. Variablen im Format ${vari
!* stimmt mit Maske NICHT überein (Platzhalter "*" ist erlaubt)
Ein Ausdruck gilt als "wahr" sofern das Ergebnis weder NULL, nicht leer und von "0" abweichend ist.
Für einen Vergleich werden Fließkommazahlen genutzt sofern es sich bei beiden Ausdrücken um gültige Nummer handelt, folgende Formate werden unterstützt:
Für einen Vergleich werden Fließkommazahlen genutzt, insofern es sich bei beiden Ausdrücken um gültige Zahlen handelt, folgende Formate werden unterstützt:
- Integer (Beispiele: 5, -7)
- Fließkommazahl (Beispiele: 5.2, -7.5, 2.83e-2)
- hexadezimale Zahl (Beispiele: 0xA3, -0xA3)
@@ -295,22 +296,25 @@ Um einen Vergleich zwischen zwei Zeichenketten zu erzwingen, müssen die Ausdrü
50 > 100 ==> 0
"50" > "100" ==> 1
Einige Variablen werden im Ausdruck, mittels der Formatierung ${variable}, ersetzt. Mögliche Variablen sind, nach Reihenfolge ihrer Priorität:
Einige Variablen werden im Ausdruck mittels der Formatierung ${variable} ersetzt. Mögliche Variablen sind, nach Reihenfolge ihrer Priorität:
1. eine evaluierte Teilzeichenkette (Format: "eval:xxx")
2. eine Zeichenkette mit Escapesequenzen (Format: "esc:xxx" oder "\xxx")
3. Zeichen welche in einer Zeichenkette nicht dargestellt werden sollen (Format: "hide:Zeichen,Zeichenkette")
3. Zeichen, die in einer Zeichenkette nicht dargestellt werden sollen (Format: "hide:Zeichen,Zeichenkette")
4. eine Zeichenkette mit einer maximalen Anzahl an Zeichen (Format: "cut:+Max,Suffix,Zeichenkette")
oder maximale Anzahl an Zeichen die auf dem Bildschirm angezeigt werden sollen (Format: "cutscr:Max,Suffix,Zeichenkette oder "cutscr:+Max,Suffix,Zeichenkette")
5. Ende einer Zeichenkette nutzen (Format: "rev:xxx")
6. Wiederholung einer Zeichenkette (Format: "repeat:Anzahl,Zeichenkette")
7. eine Farbe (Format: "color:xxx", siehe "Anleitung für API Erweiterung", Funktion "color")
8. eine Info (Format: "info:Name,Argumente", Argumente sind optional)
9. aktuelles Datum/Uhrzeit (Format: "date" oder "date:format")
10. eine Umgebungsvariable (Format: "env:XXX")
11. ein Dreifachoperand (Format: "if:Bedingung?Wert_falls_wahr:Wert_falls_unwahr")
12. eine Option (Format: "file.section.option")
13. der Name einer lokalen Variablen eines Buffer
14. ein hdata Name/Variable (der Wert wird automatisch in eine Zeichenkette konvertiert), standardmäßig wird für "window" und "buffer" das aktuelle Fenster/Buffer verwendet.
5. eine Zeichenkette umkehren (Format: "rev:xxx" oder "revscr:xxx")
6. eine Zeichenkette wiederholen (Format: "repeat:Anzahl,Zeichenkette")
7. Länge einer Zeichenkette (Format: "length:xxx" oder "lengthscr:xxx")
8. eine Farbe (Format: "color:xxx", siehe "Anleitung für API Erweiterung", Funktion "color")
9. ein Modifizierer (Format: "info:Name,Argumente", Argumente sind optional)
10. eine Info (Format: "Info:Name,Argumente", Argumente sind optional)
11. aktuelles Datum/Uhrzeit (Format: "date" oder "date:format")
12. eine Umgebungsvariable (Format: "env:XXX")
13. ein Dreifachoperand (Format: "if:Bedingung?Wert_falls_wahr:Wert_falls_unwahr")
14. Ergebnis eines Ausdrucks mit Klammern und Operatoren + - * / // % ** (Format: "calc:xxx")
15. eine Option (Format: "file.section.option")
16. eine lokale Variable eines Buffers
17. ein(e) hdata - Name/Variable (der Wert wird automatisch in eine Zeichenkette konvertiert), standardmäßig wird für "window" und "buffer" das aktuelle Fenster/Buffer verwendet.
Das Format für hdata kann wie folgt aufgebaut sein:
hdata.var1.var2...: startet mit hdata (der Pointer muss bekannt sein) und fragt eine Variable nach der anderen ab (weitere hdata können folgen)
hdata[list].var1.var2...: startet hdata mittels einer Liste, zum Beispiel:
@@ -337,6 +341,8 @@ Beispiele (einfache Zeichenketten):
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${calc:(5+2)*3} ==> 21
Beispiele (Bedingungen):
/eval -n -c ${window.buffer.number} > 2 ==> 0
@@ -351,7 +357,7 @@ Beispiele (Bedingungen):
----
[[command_weechat_filter]]
* `+filter+`: Filterfunktion um Nachrichten in Buffer aus- oder einzublenden, dazu können Schlagwörter oder reguläre Ausdrücke verwendet werden
* `+filter+`: Filterfunktion um Nachrichten in Buffern aus- oder einzublenden, dazu können Schlagwörter oder reguläre Ausdrücke verwendet werden
----
/filter list
@@ -925,7 +931,7 @@ Es ist möglich die WeeChat-Sitzung auf einem anderen Rechner wiederherzustellen
* `+uptime+`: Zeigt die Uptime von WeeChat an
----
/uptime [-o | -ol]
/uptime [-o|-ol]
-o: die Laufzeit von WeeChat wird in den aktuellen Buffer geschrieben (in englischer Sprache)
-ol: die Laufzeit von WeeChat wird in den aktuellen Buffer geschrieben (in der voreingestellten Landessprache)
@@ -935,7 +941,7 @@ Es ist möglich die WeeChat-Sitzung auf einem anderen Rechner wiederherzustellen
* `+version+`: Zeigt die WeeChat-Version und das Datum der Kompilierung an
----
/version [-o | -ol]
/version [-o|-ol]
-o: die Version von WeeChat wird in den aktuellen Buffer ausgegeben (in englischer Sprache)
-ol: die Version von WeeChat wird in den aktuellen Buffer ausgegeben (in der voreingestellten Landessprache)
+7 -1
View File
@@ -915,7 +915,7 @@
** Standardwert: `+100+`
* [[option_weechat.look.nick_color_force]] *weechat.look.nick_color_force*
** Beschreibung: pass:none[erzwingt für einen Nick eine spezielle Farbe. Die standardmäßig, mittels Streuwertfunktion aus dem Nicknamen, generierte Farbe findet für diese Nicks keine Anwendung (Format:"Nick1:Farbe1;Nick2:Farbe2"). Zuerst wird beim Namen des Nick nach Groß- und Kleinschreibung unterschieden. Sollte der Nick nicht gefunden werden findet keine Unterscheidung mehr statt. Somit ist es möglich die Nicks, für diese Einstellung, ausschließlich in Kleinschrift aufzuführen]
** Beschreibung: pass:none[erzwingt für einen Nick eine spezielle Farbe. Die standardmäßig, mittels Streuwertfunktion aus dem Nicknamen, generierte Farbe findet für diese Nicks keine Anwendung (Format:"Nick1:Farbe1;Nick2:Farbe2"). Zuerst wird beim Namen des Nick nach Groß- und Kleinschreibung unterschieden. Sollte der Nick nicht gefunden werden findet keine Unterscheidung mehr statt. Somit ist es möglich die Nicks, für diese Einstellung, ausschließlich in Kleinschrift aufzuführen; die Farbauswahl kann auch eine Hintergrundfarbe beinhalten "Textfarbe,Hintergrundfarbe", zum Beispiel "yellow,red"]
** Typ: Zeichenkette
** Werte: beliebige Zeichenkette
** Standardwert: `+""+`
@@ -926,6 +926,12 @@
** Werte: djb2, sum, djb2_32, sum_32
** Standardwert: `+djb2+`
* [[option_weechat.look.nick_color_hash_salt]] *weechat.look.nick_color_hash_salt*
** Beschreibung: pass:none[salt für den Hash-Algorithmus, der zum Auffinden von Nickfarben verwendet wird (der Nickname wird an diesen Salt angehängt und der Hash-Algorithmus verarbeitet diesen String); Wenn Sie dies ändern, werden die Nickfarben gemischt]
** Typ: Zeichenkette
** Werte: beliebige Zeichenkette
** Standardwert: `+""+`
* [[option_weechat.look.nick_color_stop_chars]] *weechat.look.nick_color_stop_chars*
** Beschreibung: pass:none[Zeichen die genutzt werden sollen damit bei der Generierung der Farbe für einen Nicknamen abgebrochen wird. Es muss mindestens ein Zeichen im Nicknamen enthalten sein der nicht in dieser Liste aufgeführt wird, damit eine Farbe für den Nicknamen erstellt werden kann (Beispiel: Der Nickname lautet "|nick|abwesend" wobei das Zeichen "|" ignoriert werden soll. Die Farbe für den Nicknamen wird nun für "|nick" anstelle von "|nick|abwesend" erstellt); diese Option hat einen Einfluss auf die Option weechat.look.nick_color_force, dort aufgeführte Nicks sollten keine Zeichen haben, die von dieser Option ignoriert werden]
** Typ: Zeichenkette
+6
View File
@@ -104,6 +104,12 @@
** Werte: beliebige Zeichenkette
** Standardwert: `+"%h/xfer"+`
* [[option_xfer.file.download_temporary_suffix]] *xfer.file.download_temporary_suffix*
** Beschreibung: pass:none[Dateiendung der temporären Datei, die während eines eingehenden Datei-Transfers genutzt wird und die gelöscht wird, sobald die Übertragung erfolgreich beendet wurde; wenn -leer-, dann wird keine temporäre Dateiendung während des Transfers genutzt]
** Typ: Zeichenkette
** Werte: beliebige Zeichenkette
** Standardwert: `+".part"+`
* [[option_xfer.file.upload_path]] *xfer.file.upload_path*
** Beschreibung: pass:none[Pfad für ausgehende Dateien (falls kein Pfad durch den Anwender angegeben wurde): "%h" wird durch das WeeChat Verzeichnis ersetzt (Standardpfad: "~/.weechat") (Hinweis: Inhalt wird evaluiert, siehe /help eval)]
** Typ: Zeichenkette
+1 -1
View File
@@ -1,7 +1,7 @@
WeeChat wird programmiert von Sébastien Helleu und weiteren Beteiligten (eine vollständige Auflistung
findet man in der AUTHORS.adoc Datei).
Copyright (C) 2003-2019 {author}
Copyright (C) 2003-2020 {author}
WeeChat is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
+420 -279
View File
File diff suppressed because it is too large Load Diff
+117 -81
View File
@@ -22,7 +22,7 @@ Die bevorzugte Terminal-Emulation für X (aber nicht obligatorisch) ist
rxvt-unicode: rxvt verfügt über eine gute UTF-8 Unterstützung und hat
keine Probleme mit der Standard Tastaturbelegung.
Programmstart aus Deiner shell:
Programmstart aus deiner Shell:
----
$ weechat
@@ -64,7 +64,7 @@ Um Optionen zu setzen benutzt man:
----
WeeChat verwendet umgehend einen neu eingestellten Wert (WeeChat muss also zu *keinem* Zeitpunkt
neu gestartet werden, nach dem die Konfiguration verändert wurde).
neu gestartet werden, nachdem die Konfiguration verändert wurde).
Beim Beenden von WeeChat werden alle Einstellungen gespeichert (mittels des
Befehls `/save` kann das Sichern der Optionen manuell durchgeführt werden).
@@ -102,33 +102,36 @@ Um weitere Informationen zum `/fset` Befehl und seine Tastenbefehle zu behalten,
siehe `/help fset`.
[[core_vs_plugins]]
== Kern (Core) vs Erweiterungen
== Kern (Core) vs. Erweiterungen
Der Kern (core) von WeeChat
dient ausschließlich der Ausgabe von Daten auf dem Bildschirm
und der Interaktion mit dem Benutzer.
WeeChat - also der WeeChat-Kern - ist somit ohne jedwede Erweiterung
eigentlich™ unbrauchbar für die Nutzung als Kommunikationswerkzeug im Internet.
Alle Netzwerkprotokolle (z.B. IRC) werden als separate Erweiterung bereitgestellt.
Der Kern (core) von WeeChat dient ausschließlich dazu um Daten auf dem Bildschirm
auszugeben und um mit dem Benutzer zu interagieren. Dies bedeutet das WeeChat,
-also der WeeChat core-, ohne jedwede Erweiterung, unbrauchbar ist.
(an die treuen User: IRC war Teil des Kerns in den Versionen ≤ 0.2.6)
Alle Netzwerkprotokolle, z.B. IRC, werden als separate Erweiterung bereit gestellt.
Benutze den Befehl `/plugin` um alle Erweiterungen aufzulisten, "irc" sowie andere
Erweiterungen sollten aufgelistet werden.
[[create_irc_server]]
== Einen IRC-Server erstellen
Um eine Verbindung zu einem IRC Server herzustellen wird der
Um eine Verbindung zu einem IRC Server herzustellen, wird der
`/server` Befehl verwendet. Beispiel:
----
/server add freenode chat.freenode.net
----
In dieser Zeile ist `freenode` der interne Servername der von WeeChat genutzt wird:
Damit ist es möglich sich mit dem Server zu verbinden `/connect freenode` und um
die Server relevanten Optionen anzupassen _irc.server.freenode.xxx_.
In diesem Beispiel ist `freenode` der interne, von Weechat genutzte Servername.
Mit dem Befehl `/connect freenode` kann jetzt die Verbindung
zu diesem Freenode-IRC-Server aufgebaut werden.
Alle für den Server relevanten Optionen sind unter _irc.server.freenode.xxx_ zu finden.
Falls noch Fragen offen sein sollten, einfach die Hilfe verwenden:
Verwende die Hilfe, falls noch Fragen offen sind:
----
/help server
@@ -139,50 +142,53 @@ Falls noch Fragen offen sein sollten, einfach die Hilfe verwenden:
WeeChat verwendet Vorgabewerte für alle Server (so genannte "fall backs"), sofern
keine individuellen Werte für die entsprechenden Server-Optionen gesetzt worden sind.
Die Vorgabewerte sind in "irc.server_default.*" hinterlegt.
Die Vorgabewerte sind in den Optionen _irc.server_default.xxx_ hinterlegt.
Für jede Server-Option benutzt WeeChat den individuellen Wert - falls einer
definiert ist (nicht "null"). Andernfalls verwendet WeeChat die Vorgabewerte
("irc.server_default.xxx").
(_irc.server_default.xxx_).
Beispielsweise werden Standard Nicks verwendet (basierend auf dem Un*x Login). Um
dies nun für den freenode-Server anzupassen, kann folgender Befehl genutzt werden:
Beispielsweise werden Standard Nicks verwendet (basierend auf dem Un*x Login).
Sollen speziell für den freenode-Server andere Nicks genutzt werden,
können diese mit folgendem Befehl angepasst werden:
----
/set irc.server.freenode.nicks "meinNick,meinNick2,meinNick3,meinNick4,meinNick5"
----
Um den User- und realen Namen anzupassen:
Benutzernamen und wirklichen Namen (realname) anpassen:
----
/set irc.server.freenode.username "Mein User-Name"
/set irc.server.freenode.username "Mein Benutzername"
/set irc.server.freenode.realname "Mein wirklicher Name"
----
Um beim Start von WeeChat automatisch eine Verbindung zu einem Server
herzustellen:
Beim Start von WeeChat automatisch die Verbindung zu einem Server herstellen:
----
/set irc.server.freenode.autoconnect on
----
Um eine SSL Verbindung herzustellen:
Beim Verbindungsaufbau SSL (sichere Verbindung) nutzen:
----
/set irc.server.freenode.addresses "chat.freenode.net/7000"
/set irc.server.freenode.ssl on
----
Sollte der Server SASL unterstützen, kann man sich damit automatisch Authentifizieren
(dadurch identifiziert man sich beim Server, bevor man Channels (Chaträume) betritt):
Wenn der Server SASL unterstützt,
kann die Authentifizierung des Benutzers schon beim Aufbau der IRC-Session stattfinden.
Der Benutzer wird auf diese Weise gegenüber dem IRC-Server identifiziert,
noch bevor Server-Befehle übermittelt oder Cannels (Chaträume) betreten werden können.
----
/set irc.server.freenode.sasl_username "mynick"
/set irc.server.freenode.sasl_password "xxxxxxx"
----
Unterstützt der Server keine SASL Authentifizierung, muss man sich bei "nickserv"
identifizieren:
Wenn der Server keine SASL-Authentifizierung unterstützt,
muss der Benutzer sich nach dem Verbindungsaufbau bei "nickserv" identifizieren.
Der dafür notwendige IRC-Server-Befehl kann auch automatisch übermittelt werden:
----
/set irc.server.freenode.command "/msg nickserv identify xxxxxxx"
@@ -191,31 +197,34 @@ identifizieren:
[NOTE]
Mehrere Befehle in der Option _command_ können durch ein `;` (Semikolon) voneinander getrennt werden.
Möchte man seine Passwörter nicht als Klartext in der Konfiguration sichern, kann man die
Erweiterung /secure nutzen.
Sollen Passwörter nicht als Klartext in der Konfiguration sichtbar sein,
kann die Erweiterung _/secure_ genutzt werden.
Zuerst sollte eine Passphrase gesetzt werden:
Zuerst sollte die Passphrase gesetzt werden:
----
/secure passphrase Dies ist meine geheime Passphrase
----
Dann kann man zum Beispiel für Freenode ein geheimes Passwort setzen:
Jetzt wird das Passwort (`xxxxxx`)
für den Zugang zum Freenode-Server verschlüsselt
und mit dem Bezeichner `freenode_password` verknüpft:
----
/secure set freenode_password xxxxxxx
/secure set freenode_password xxxxxx
----
Um nun das geschützte Freenode-Passwort in einer Option zu nutzen setzt man eine
Variable anstelle des Passworts, `+${sec.data.freenode_password}+`:
Das geschützte Freenode-Passwort kann nun in anderen Optionen genutzt werden.
Dazu wird anstelle des Klartext-Passwortes die Variable
`+${sec.data.freenode_password}+` eingesetzt:
----
/set irc.server.freenode.sasl_password "${sec.data.freenode_password}"
----
Um ein auto-join (automatisches _betreten_) von Channels (Räumen) nach der
Verbindung zum Server durchzuführen, müssen die entsprechenden Channels in
eine Liste eingetragen werden:
Das automatische Betreten (auto-join) von Channels (Chaträume) direkt nach dem
Verbindungsaufbau zum IRC-Server kann durch den Eintrag der gewünschten Channels
in folgender Option erreicht werden:
----
/set irc.server.freenode.autojoin "#channel1,#channel2"
@@ -224,31 +233,37 @@ eine Liste eingetragen werden:
[TIP]
Mittels der kbd:[Tab] Taste kann man sehr einfach Namen und Werte von Optionen
vervollständigen und mittels kbd:[Shift+Tab] kann eine teilweise Vervollständigung
durchgeführt werden (was bei langen Wörtern, wie z.B. der Name einer Option, nützlich
durchgeführt werden (was bei langen Wörtern, wie z.B. dem Namen einer Option, nützlich
sein kann).
Um einen Wert der Server-Optionen zu entfernen und stattdessen wieder den
Vorgabewert zu nutzen, z.B. Nutzen der vorgegebenen Nicknamen
(irc.server_default.nicks):
Mit dem Befehl `/unset` können Server-Optionen zurückgesetzt werden.
Ist eine Server-Option zurückgesetzt, _wirkt_ der entsprechende Vorgabewert
aus dem fall-back-Bereich `irc.server_default.xxx`. So nimmt, beispielsweise
nach dem Rücksetzen der Freenode-Nicks, diese Server-Option _automatisch_ den Wert
der entsprechenden fall-back-Option `irc.server_default.nicks` an:
----
/unset irc.server.freenode.nicks
----
Andere Optionen: Du kannst andere Optionen mit folgendem Befehl festlegen ("xxx"
ist der Optionsname):
*Andere Optionen:*
Werte anderer Server-Optionen (`xxx`) können festgelegt werden mit:
----
/set irc.server.freenode.xxx Wert
----
[[connect_to_irc_server]]
== Verbinden mit dem IRC-Server und auto-join der Channel
== Verbinden mit dem IRC-Server
----
/connect freenode
----
Mittels obigem Befehl stellt WeeChat eine Verbindung zum freenode Server
her und betritt automatisch die Kanäle die in der "autojoin" Server-Option
aufgeführt sind.
[NOTE]
Dieser Befehl kann dazu benutzt werden um einen neuen Server zu erstellen und
sich mit diesem zu verbinden, ohne den Befehl `/server` zu benutzen
@@ -268,7 +283,7 @@ um dadurch separate Server-Buffer zu erhalten:
[[join_part_irc_channels]]
== Betreten/verlassen der IRC-Channel
Einen Channel betreten:
Einen Channel (Chatraum) betreten:
----
/join #channel
@@ -277,22 +292,23 @@ Einen Channel betreten:
Einen Channel verlassen (der Buffer bleibt dabei geöffnet):
----
/part [quit message]
/part [Verlassen-Nachricht]
----
Schließt einen Server, Channel oder privaten Buffer (`/close` ist ein Alias
für `/buffer close`):
Einen Buffer schließen (Server, Channel, privater Buffer);
`/close` ist dabei ein Alias für `/buffer close`:
----
/close
----
[WARNING]
Wird ein Server-Buffer geschlossen, werden automatisch die Channel/privaten
Buffer geschlossen.
Wird ein Server-Buffer geschlossen,
schließt WeeChat ebenfalls alle zum Server
gehörenden Channels und privaten Buffer.
Um sich bei einem Server abzumelden, führt man im entsprechenden Server-Buffer
folgenden Befehl aus:
Die Abmeldung von einem Server erfolgt im entsprechenden Server-Buffer
mit Hilfe des Befehls:
----
/disconnect
@@ -301,13 +317,15 @@ folgenden Befehl aus:
[[irc_private_messages]]
== IRC private Nachrichten
Öffnet einen Buffer und schickt eine Nachricht an einen User (Nick _foo_):
Schicke eine Nachricht an einen bestimmten Benutzer (hier: _foo_)
und öffne einen privaten Buffer (Nachrichten in diesem Buffer
sehen nur der andere Benutzer und ich):
----
/query foo Dies ist eine Nachricht
----
Schließt einen privaten Buffer:
Schließe den privaten Buffer:
----
/close
@@ -316,16 +334,19 @@ Schließt einen privaten Buffer:
[[buffer_window]]
== Buffer/Fenster Verwaltung
Ein Buffer ist einer Erweiterung zugeordnet und besitzt eine Buffer-Nummer,
einen Buffer-Namen und beinhaltet die auf dem Bildschirm dargestellten
Zeilen.
Ein Buffer ist einer Erweiterung zugeordnet
und besitzt sowohl eine Buffer-Nummer als auch einen Buffer-Namen.
Die innerhalb eines Fensters dargestellten Zeilen/Zeichen
werden aus dem Inhalt des Buffers generiert.
Ein Fenster ist die Ansicht eines Buffers. Standardmäßig nutzt WeeChat ein
Fenster, in welchem ein Buffer darstellt wird. Wird der Bildschirm in
mehrere Fenster aufgeteilt, kann man sich entsprechend der Anzahl der
geteilten Fenster einen Buffer pro Fenster anzeigen lassen.
Ein Fenster ist der Ausschnitt der Programmoberfläche,
den WeeChat für einen bestimmten Buffer bereitstellt.
Standardmäßig nutzt WeeChat genau ein Fenster pro darzustellendem Buffer.
Wird der Bildschirm in mehrere Fenster aufgeteilt,
können, entsprechend der Anzahl der Fenster,
die gleiche Anzahl an Buffern angezeigt werden.
Befehle, zum Verwalten von Buffern und Fenstern:
Befehle zum Verwalten von Buffern und Fenstern:
----
/buffer
@@ -348,9 +369,9 @@ Um die Teilung des Bildschirms rückgängig zu machen:
[[key_bindings]]
== Tastaturbelegung
WeeChat verwendet viele Standardtasten. Alle Tastenbelegungen sind in der
Dokumentation beschrieben. Im folgenden werden die wichtigsten Tastenbelegungen
kurz erläutert:
WeeChat verwendet viele Standardtasten.
Alle Tastenbelegungen sind in der Dokumentation beschrieben.
Im Folgenden werden die wichtigsten Tastenbelegungen kurz erläutert:
- kbd:[Alt+←] / kbd:[Alt+→] oder kbd:[F5] / kbd:[F6]: Wechsel zum
vorherigen/nächsten Buffer
@@ -363,11 +384,16 @@ kurz erläutert:
- kbd:[PgUp] / kbd:[PgDn]: scrollt den Text im aktiven Buffer
- kbd:[Alt+a]: springt zum Buffer mit Aktivität (aus der Hotlist)
Gemäß Deiner Tastatur und/oder Deinen Bedürfnissen kann jede Taste mit Hilfe
des `/key` Befehls durch jedweden Befehl neu belegt werden.
Eine nützliche Tastenkombination um Tastencodes zu ermitteln ist kbd:[Alt+k].
Die Tastenbelegung WeeChat's kann sowohl an deine persönlichen Vorlieben
als auch an die Besonderheiten deiner Tastatur angepasst werden.
Mit Hilfe des Befehls `/key` wird einer bestimmten Taste oder Tastenkombination
ein WeeChat-Befehl zugeordnet.
Beispiel: Belegung von kbd:[Alt+!] mit dem Befehl `/buffer close`:
In diesem Zusammenhang ist die Standard-Tastenkombination kbd:[Alt+k] besonders
hervorzuheben. Sie ermittelt (auf magische Weise) beliebige Tastaturcodes.
Beispiel:
Belege die Tastenkombination kbd:[Alt+!] mit dem Befehl `/buffer close`:
----
/key bind (drücke alt-k) (drücke alt-!) /buffer close
@@ -379,7 +405,7 @@ Du wirst folgende Befehlszeile erhalten:
/key bind meta-! /buffer close
----
Entfernen der Tastenbelegung:
Entferne die Tastenbelegung kbd:[Alt+!]:
----
/key unbind meta-!
@@ -388,28 +414,38 @@ Entfernen der Tastenbelegung:
[[plugins_scripts]]
== Erweiterungen/Skripten
Bei einigen Distributionen wie z.B. Debian, sind die Erweiterungen über separate Pakete
erhältlich (z.B. weechat-plugins).
Erweiterungen werden -sofern welche gefunden worden sind- automatisch geladen (Bitte beachte
die Dokumentation zum installieren/entfernen von Erweiterungen und/oder Skripten).
Bei einigen Distributionen (z.B. Debian),
sind die WeeChat-Erweiterungen über separate Pakete erhältlich (z.B. _weechat-plugins_).
Erweiterungen werden, insofern sie beim Start von WeeChat gefunden wurden,
automatisch geladen (Bitte beachte die Dokumentation zum Installieren
und Entfernen von Erweiterungen und/oder Skripten).
Viele externe Skripten (von Drittprogrammierern) sind für WeeChat verfügbar. Diese
Skripten können mittels des `/script` Befehls heruntergeladen und installiert werden:
Viele externe Skripten (von Drittprogrammierern) sind für WeeChat verfügbar.
Diese Skripten können mit Hilfe des `/script`-Befehls heruntergeladen
und installiert werden:
----
/script install go.py
----
siehe `/help script` für weitere Informationen.
Zeige weitere Informationen:
----
/help script
----
Eine Liste aller verfügbaren Skripten kann man sich in WeeChat mittels
`/script` anzeigen lassen oder man besucht folgende Webseite:
https://weechat.org/scripts
Zeige eine liste aller verfügbaren Skripten:
----
/script
----
Auf *weechat.org* von Drittanbietern bereitgestellte Scripten: https://weechat.org/scripts
[[more_doc]]
== Weitere Dokumentation
Nun kannst Du WeeChat nutzen, für weitere Fragen lese die FAQ und/oder Dokumentation:
https://weechat.org/doc
Mit dieser Quickstart-Anleitung wurden dir die wesentlichen
Bedienungswerkzeuge von WeeChat nähergebracht.
Für das eingehende Studium aller verfügbaren Funktionalitäten
sei dir unsere ausführliche FAQ/Dokumentation ans Herz gelegt: https://weechat.org/doc
Viel Spass mit WeeChat!
+134 -31
View File
@@ -3,9 +3,10 @@
:email: flashcode@flashtux.org
:lang: de
:toc: left
:toclevels: 3
:toclevels: 4
:toc-title: Inhaltsverzeichnis
:sectnums:
:sectnumlevels: 3
:docinfo1:
@@ -73,22 +74,93 @@ und die Dokumentation für die Funktion `hook_process` in link:weechat_plugin_ap
==== Python
* WeeChat muss als Modul eingebunden werden: `import weechat`
* Um die WeeChat Funktion `+print*+` nutzen zu können muss `+prnt*+` genutzt
werden (_print_ ist ein reservierter Befehl von Python!)
* Funktionen werden im Format `weechat.xxx(arg1, arg2, ...)` ausgeführt
===== Module
WeeChat definiert ein `weechat` Module welches mittels `import weechat`
importiert werden muss.
===== Funktionen
Funktionen werden aufgerufen mittels `weechat.xxx(arg1, arg2, ...)`.
Die Funktionen `+print*+` werden bei python durch `+prnt*+` ersetzt
(`print` war ein reserviertes Schlüsselwort unter Python 2).
===== In Callbacks empfangene Zeichen
Mit Python 3 und WeeChat ≥ 2.7 sind die Zeichenketten in Callbacks
vom Typ `str`, sofern die Zeichenketten gültige UTF-8 Daten enthalten
(was am häufigsten zutreffen sollte), oder vom Typ `bytes` falls
die Zeichenkette keine gültigen UTF-8 Daten enthält. Deshalb sollte
im Callback darauf geachtet werden das ungültige UTF-8 Daten
empfangen werden können.
In folgenden Fällen können einige ungültige UTF-8-Daten empfangen werden,
sodass im Callback Zeichenketten vom Typ `str` oder `bytes` (diese
Liste ist nicht vollständig):
[width="100%",cols="3m,3m,3m,8",options="header"]
|===
| API Funktion | Argumente | Beispiele| Beschreibung
| hook_modifier |
irc_in_yyy |
pass:[irc_in_privmsg] +
pass:[irc_in_notice] |
Eine Nachricht die von der IRC Erweiterung empfangen wurde und bevor sie nach UTF-8 dekodiert wurde (intern
verwendet). +
+
Es wird empfohlen den Modifier `irc_in2_yyy` zu nutzen, da die empfangene Zeichenkette
immer UTF-8 gültig ist. +
siehe Funktion `hook_modifier` in der
link:weechat_plugin_api.en.html#_hook_modifier[WeeChat Anleitung für API Erweiterung].
| hook_signal |
xxx,irc_out_yyy +
xxx,irc_outtags_yyy |
pass:[*,irc_out_privmsg] +
pass:[*,irc_out_notice] +
pass:[*,irc_outtags_privmsg] +
pass:[*,irc_outtags_notice] |
Eine Nachricht welche von der IRC Erweiterung versendet wurde, nachdem diese entsprechend
der Benutzereinstellung `encode` Charset kodiert (falls abweichend von der `UTF-8` Standardeinstellung). +
+
Es wird empfohlen das Signal `xxx,irc_out1_yyy` zu nutzen, da die empfangene Zeichenkette
immer UTF-8 gültig ist. +
siehe Funktion `hook_signal` in der
link:weechat_plugin_api.en.html#_hook_signal[WeeChat Anleitung für API Erweiterung].
| hook_process +
hook_process_hashtable |
- |
- |
Ausgabe des Befehls, dass an den Callback gesendet wurde, kann ungültige UTF-8 Daten enthalten.
|===
Mit Python 2, das mittlerweile veraltet ist und nicht mehr verwendet werden sollte, ist die
Zeichenkette die an die Callbacks gesendet wird immer vom Typ `str` und kann deshalb bei den
oben genannten Fällen, ungültige UTF-8 Daten enthalten.
==== Perl
* Funktionen werden im Format `weechat::xxx(arg1, arg2, ...);` ausgeführt
===== Funktionen
Funktionen werden aufgerufen mittels `weechat::xxx(arg1, arg2, ...);`.
==== Ruby
* Es muss _weechat_init_ definiert und darin die Funktion _register_ ausgeführt werden
* Funktionen werden im Format `Weechat.xxx(arg1, arg2, ...)` ausgeführt
* Aufgrund einer Limitierung, seitens Ruby (maximal 15 Argumente pro Funktion), empfängt
die Funktion `Weechat.config_new_option` den Callback in einem Array von 6 Strings
(3 Callbacks + 3 Data Strings), somit sieht ein Aufruf der Funktion folgendermaßen aus:
===== Initialization
Es muss _weechat_init_ definiert werden und darin dann _register_ ausgeführt werden.
===== Functions
Funktionen werden aufgerufen mittels `Weechat.xxx(arg1, arg2, ...)`.
Aufgrund einer Beschränkung von Ruby (maximal 15 Argumente pro Funktion), empfängt
die Funktion `Weechat.config_new_option` ein Callback mit einem Array von 6 Zeichenketten
(3 Callbacks + 3 Datenzeichenketten), so sieht ein Aufruf dieser Funktion aus:
[source,ruby]
----
@@ -98,29 +170,41 @@ Weechat.config_new_option(config, section, "name", "string", "description of opt
==== Lua
* Funktionen werden im Format `weechat.xxx(arg1, arg2, ...)` ausgeführt
===== Funktionen
Funktionen werden aufgerufen mittels `weechat.xxx(arg1, arg2, ...)`.
==== Tcl
* Funktionen werden im Format `weechat::xxx arg1 arg2 ...` ausgeführt
===== Funktionen
Funktionen werden aufgerufen mittels `weechat::xxx arg1 arg2 ...`.
==== Guile (Scheme)
* Funktionen werden im Format `(weechat:xxx arg1 arg2 ...)` ausgeführt
* folgende Funktionen nutzen eine Liste von Argumente (anstelle von vielen
Argumenten für andere Funktionen), dies liegt daran das Guile die Anzahl
der Argumente eingeschränkt ist:
** config_new_section
** config_new_option
** bar_new
===== Funktionen
Funktionen werden aufgerufen mittels `(weechat:xxx arg1 arg2 ...)`.
Die folgenden Funktionen verwenden eine Liste von Argumenten (anstelle vieler Argumente
für andere Funktionen), da die Anzahl der Argumente die zulässige Anzahl in Guile
überschreiten würde:
* config_new_section
* config_new_option
* bar_new
==== JavaScript
* Funktionen werden im Format `weechat.xxx(arg1, arg2, ...);` ausgeführt
===== Funktionen
Funktionen werden aufgerufen mittels `weechat.xxx(arg1, arg2, ...);`.
==== PHP
* Funktionen werden im Format `weechat_xxx(arg1, arg2, ...);` ausgeführt
===== Functions
Funktionen werden aufgerufen mittels `weechat_xxx(arg1, arg2, ...);`.
[[register_function]]
=== Die "Register" Funktion
@@ -1103,15 +1187,20 @@ weechat.prnt("", "Wert der Option weechat.color.chat_delimiters ist: %s"
[[irc_catch_messages]]
==== Nachrichten abfangen
Die IRC Erweiterung sendet zwei Signale wenn eine Nachricht empfangen wurde.
`xxx` ist der interne IRC Servername, `yyy` ist der IRC Befehl der empfangen
wurde (JOIN, QUIT, PRIVMSG, 301, ..):
Die IRC Erweiterung sendet vier Signale wenn eine Nachricht empfangen wurde
(`xxx` ist dabei der interne Servername, `yyy` ist der IRC Befehl z.B. JOIN, QUIT, PRIVMSG, 301, ..):
xxxx,irc_in_yyy::
Signal wird gesendet bevor die Nachricht verarbeitet wurde.
xxx,irc_in_yyy::
Signal wird gesendet, bevor die Nachricht verarbeitet wird, nur wenn Nachricht *nicht* ignoriert wird
xxx,irc_in2_yyy::
Signal wird gesendet nachdem die Nachricht verarbeitet wurde.
Signal wird gesendet, nachdem die Nachricht verarbeitet wird, nur wenn Nachricht *nicht* ignoriert wird
xxx,irc_raw_in_yyy::
Signal wird gesendet, bevor die Nachricht verarbeitet wird, auch wenn Nachricht ignoriert wird
xxx,irc_raw_in2_yyy::
Signal wird gesendet, nachdem die Nachricht verarbeitet wird, auch wenn Nachricht ignoriert wird
[source,python]
----
@@ -1133,8 +1222,17 @@ weechat.hook_signal("*,irc_in2_join", "join_cb", "")
[[irc_modify_messages]]
==== Nachrichten ändern
Die IRC Erweiterung verschickt einen "modifier" mit Namen "irc_in_xxx" ("xxx" steht für den
Namen des IRC Befehls) falls eine Nachricht empfangen wurde die dann modifiziert werden kann.
Die IRC Erweiterung sendet zwei "Modifier" für eine empfangene Nachricht
("xxx" ist der IRC Befehl), damit die Nachricht verändert werden kann:
irc_in_xxx::
Modifier, der vor der Zeichensatzdekodierung gesendet wurde: diese Zeichenkette
sollte mit Vorsicht verwendet werden, da sie ungültige UTF-8-Daten enthalten kann;
Nur bei Rohoperationen für eine Nachricht verwenden
irc_in2_xxx::
Modifier wird nach der Zeichensatzdekodierung gesendet, sodass die empfangene
Zeichenkette immer eine gültige UTF-8 Kodierung enthält (*empfohlen*)
[source,python]
----
@@ -1143,7 +1241,7 @@ def modifier_cb(data, modifier, modifier_data, string):
# (Okay dies ist nicht wirklich sinnvoll, aber es ist auch nur ein Beispiel!)
return "%s %s" % (string, modifier_data)
weechat.hook_modifier("irc_in_privmsg", "modifier_cb", "")
weechat.hook_modifier("irc_in2_privmsg", "modifier_cb", "")
----
[WARNING]
@@ -1177,6 +1275,10 @@ Das Ergebnis ist eine Hashtabelle mit folgenden Schlüsseln
der ursprüngliche Nick. |
`nick`
| user | ≥ 2.7 |
der ursprüngliche Benutzer. |
`user`
| host | ≥ 0.3.4 |
der ursprüngliche Host (beinhaltet den Nick). |
`nick!user@host`
@@ -1224,6 +1326,7 @@ dict = weechat.info_get_hashtable(
# "tags": "time=2015-06-27T16:40:35.000Z",
# "message_without_tags": ":nick!user@host PRIVMSG #weechat :hello!",
# "nick": "nick",
# "user": "user",
# "host": "nick!user@host",
# "command": "PRIVMSG",
# "channel": "#weechat",
+144 -43
View File
@@ -108,7 +108,7 @@ zu kompilieren und welche Pakete optional genutzt werden können.
| libncursesw5-dev ^(2)^ | | *ja* | Ncurses Oberfläche.
| libcurl4-gnutls-dev | | *ja* | URL Transfer.
| zlib1g-dev | | *ja* | Kompression für Pakete, die mittels Relay- (WeeChat Protokoll), Script-Erweiterung übertragen werden.
| libgcrypt20-dev | | *ja* | Geschützte Daten, IRC SASL Authentifikation (DH-BLOWFISH/DH-AES), Skript-Erweiterung.
| libgcrypt20-dev | | *ja* | Geschützte Daten, IRC SASL Authentifikation (DH-BLOWFISH/DH-AES).
| libgnutls28-dev | ≥ 2.2.0 ^(3)^ | | SSL Verbindung zu einem IRC Server, Unterstützung von SSL in der Relay-Erweiterung, IRC SASL Authentifikation (ECDSA-NIST256P-CHALLENGE).
| gettext | | | Internationalisierung (Übersetzung der Mitteilungen; Hauptsprache ist englisch).
| ca-certificates | | | Zertifikate für SSL Verbindungen.
@@ -116,7 +116,7 @@ zu kompilieren und welche Pakete optional genutzt werden können.
∥ libenchant-dev | | | Spell Erweiterung.
| python3-dev | ^(4)^ | | Python Erweiterung.
| libperl-dev | | | Perl Erweiterung.
| ruby2.5, ruby2.5-dev | ≥ 1.8 | | Ruby Erweiterung.
| ruby2.5, ruby2.5-dev | ≥ 1.9.1 | | Ruby Erweiterung.
| liblua5.3-dev | | | Lua Erweiterung.
| tcl-dev | ≥ 8.5 | | Tcl Erweiterung.
| guile-2.0-dev | ≥ 2.0 | | Guile (scheme) Erweiterung.
@@ -798,13 +798,22 @@ Um sich alle verfügbaren Farben anzeigen zu lassen, die der Terminal
unterstützt, kann man in WeeChat die Tastenkombination kbd:[Alt+c]
im `/color` Buffer nutzen oder im Terminal den Befehl `weechat --colors` ausführen.
Beispiel: Im Buffer wird "Hallo an alle!" ausgegeben. Dabei wird "Hallo" in Fettschrift
und hellblau und "an alle" rot und unterstrichen dargestellt.
Beispiel: Im Buffer wird "Hallo Alice!" ausgegeben. Dabei wird "Hallo" in Fettschrift
und hellblau und "Alice" rot und unterstrichen dargestellt.
----
^Cc12^CbHallo ^Cb^Cc04^C_an alle^C_^Cc!
^Cc12^CbHallo ^Cb^Cc04^C_Alice^C_^Cc!
----
Tastenbefehl:
kbd:[Ctrl+c] kbd:[c] kbd:[1] kbd:[2] kbd:[Ctrl+c] kbd:[b] +
kbd:[H] kbd:[a] kbd:[l] kbd:[l] kbd:[o] kbd:[Space] +
kbd:[Ctrl+c] kbd:[b] kbd:[Ctrl+c] kbd:[c] kbd:[0] kbd:[4] kbd:[Ctrl+c] kbd:[pass:[_]] +
kbd:[A] kbd:[l] kbd:[i] kbd:[c] kbd:[e] +
kbd:[Ctrl+c] kbd:[pass:[_]] kbd:[Ctrl+c] kbd:[c] +
kbd:[!]
[NOTE]
Die Farben können in der IRC Erweiterung neu belegt werden,
mittels der Option <<option_irc.color.mirc_remap,irc.color.mirc_remap>>.
@@ -1803,44 +1812,125 @@ Diese Tasten werden im Kontext "mouse" verwendet, wenn eine Mausfunktion genutzt
[width="100%",cols="^.^3,^.^3,^.^3,.^8,.^8",options="header"]
|===
| Maustaste/Mausrad ^(1)^ | Mausgeste | Bereich | Beschreibung | Befehl
| ◾◽◽ | - | Chat | wechselt zum Fenster. | `/window ${_window_number}`
| ◾◽◽ | links | Chat | zum vorherigen Buffer springen. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | rechts | Chat | zum nächsten Buffer springen. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | links(lang) | Chat | wechselt zum ersten Buffer. | `/window ${_window_number};/buffer 1`
| ◾◽◽ | rechts(lang) | Chat | wechselt zum letzten Buffer. | `/window ${_window_number};/input jump_last_buffer`
| ◾◽◽ | - | chat (script buffer) | wählt einen Eintrag im Script-Buffer aus. | `/script go ${_chat_line_y}`
| ◽◽◾ | - | chat (script buffer) | installiert/entfernt ein Skript. | `/script go ${_chat_line_y};/script installremove -q ${script_name_with_extension}`
| kbd:[▲] | - | Chat | mehrere Zeilen im Verlaufsspeicher des Buffer nach oben blättern. | `/window scroll_up -window ${_window_number}`
| kbd:[▼] | - | Chat | mehrere Zeilen im Verlaufsspeicher des Buffer nach unten blättern. | `/window scroll_down -window ${_window_number}`
| kbd:[▲] | - | chat (script buffer) | fünf Zeilen nach oben blättern, im Script-Buffer. | `/script up 5`
| kbd:[▼] | - | chat (script buffer) | fünf Zeilen nach unten blättern, im Script-Buffer. | `/script down 5`
| kbd:[Ctrl+▲] | - | chat | horizontal, nach links scrollen. | `/window scroll_horiz -window ${_window_number} -10%`
| kbd:[Ctrl+▼] | - | chat | horizontal, nach rechts scrollen. | `/window scroll_horiz -window ${_window_number} +10%`
| ◽◽ | up / left | buflist | verschiebt Buffer in der Reihenfolge nach unten. | Signal `buflist_mouse`.
| ◽◽ | down / right | buflist | verschiebt Buffer in der Reihenfolge nach oben. | Signal `buflist_mouse`.
| ◽◽ | - | buflist | wechselt zum Buffer (oder zum vorherigen Buffer, falls der aktuell genutzte Buffer angewählt wurde). | Signal `buflist_mouse`.
| ◽◽◾ | - | buflist | wechselt zum nächsten Buffer, falls der aktuell genutzte Buffer angewählt wurde. | Signal `buflist_mouse`.
| kbd:[Ctrl+▲] | - | buflist | wechselt zum vorherigen Buffer. | Signal `buflist_mouse`.
| kbd:[Ctrl+▼] | - | buflist | wechselt zum nächsten Buffer. | Signal `buflist_mouse`.
| ◽◽ | hoch | Benutzerliste | Benutzerliste um eine Seite nach oben blättern. | `/bar scroll nicklist ${_window_number} -100%`
| ◾◽◽ | runter | Benutzerliste | Benutzerliste um eine Seite nach unten blättern. | `/bar scroll nicklist ${_window_number} +100%`
| ◾◽◽ | hoch(lang) | Benutzerliste | springt zum Anfang der Benutzerliste. | `/bar scroll nicklist ${_window_number} b`
| ◾◽◽ | runter(lang) | Benutzerliste | springt zum Ende der Benutzerliste. | `/bar scroll nicklist ${_window_number} e`
| ◽◽ | - | Benutzerliste | öffnet privaten Chat mit Nick. | `/window ${_window_number};/query ${nick}`
| ◽◽◾ | - | Benutzerliste | führt einen whois für Nick aus. | `/window ${_window_number};/whois ${nick}`
| ◾◽◽ | links | Benutzerliste | kickt Nick. | `/window ${_window_number};/kick ${nick}`
| ◾◽◽ | links(lang) | Benutzerliste | kickt und verbannt Nick. | `/window ${_window_number};/kickban ${nick}`
| ◽◽ | links | Benutzerliste | verbannt Nick. | `/window ${_window_number};/ban ${nick}`
| ◽◽ | - | Input | fängt ein Mausereignis und fügt dieses in die Befehlszeile ein. | `/input grab_mouse_area`
| kbd:[▲] | - | jede Bar | blättert Bar um 20% nach oben. | `/bar scroll ${_bar_name} ${_window_number} -20%`
| kbd:[▼] | - | jede Bar | blättert Bar um 20% nach unten. | `/bar scroll ${_bar_name} ${_window_number} +20%`
| ◽◽ | - | überall | aktiviert den Cursor-Modus an dieser Position. | `/cursor go ${_x},${_y}`
| Maustaste/Mausrad ^(1)^ | Mausgeste | Bereich | Beschreibung | Befehl
| ◾◽◽ | - | Chat | wechselt zum Fenster. | `/window ${_window_number}`
| ◾◽◽ | links | Chat | zum vorherigen Buffer springen. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | rechts | Chat | zum nächsten Buffer springen. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | links(lang) | Chat | wechselt zum ersten Buffer. | `/window ${_window_number};/buffer 1`
| ◾◽◽ | rechts(lang) | Chat | wechselt zum letzten Buffer. | `/window ${_window_number};/input jump_last_buffer`
| kbd:[▲] | - | Chat | mehrere Zeilen im Verlaufsspeicher des Buffer nach oben blättern. | `/window scroll_up -window ${_window_number}`
| kbd:[▼] | - | Chat | mehrere Zeilen im Verlaufsspeicher des Buffer nach unten blättern. | `/window scroll_down -window ${_window_number}`
| kbd:[Ctrl+▲] | - | chat | horizontal, nach links scrollen. | `/window scroll_horiz -window ${_window_number} -10%`
| kbd:[Ctrl+▼] | - | chat | horizontal, nach rechts scrollen. | `/window scroll_horiz -window ${_window_number} +10%`
| kbd:[▲] | - | chat: fset Buffer | Auswahl wird fünf Einträge nach oben bewegt, im fset Buffer. | `/fset -up 5`
| kbd:[▼] | - | chat: fset buffer | Auswahl wird fünf Einträge nach unten bewegt, im fset Buffer. | `/fset -down 5`
| ◾◽◽ | - | chat: fset buffer | springt zu einem Eintrag im fset Buffer. | `/window ${_window_number};/fset -go ${_chat_line_y}`
| ◽◽◾ | - | chat: fset buffer | Boolean-Wert wird umgeschaltet (an/aus) oder editiere den Wert einer Option. | `hsignal:fset_mouse`
| ◽◽ | left | chat: fset buffer | Integer/Farbwerte werden verringert, andere Variabletypen werden in die Eingabezeile kopiert. | `hsignal:fset_mouse`
| ◽◽ | right | chat: fset buffer | Integer/Farbwerte werden erhöht, andere Variabletypen werden in die Eingabezeile kopiert. | `hsignal:fset_mouse`
| ◽◽ | up / down | chat: fset buffer | markieren/demarkieren von mehreren Optionen. | `hsignal:fset_mouse`
| kbd:[▲] | - | chat: script buffer | fünf Zeilen nach oben blättern, im Script-Buffer. | `/script up 5`
| kbd:[▼] | - | chat: script buffer | fünf Zeilen nach unten blättern, im Script-Buffer. | `/script down 5`
| ◾◽◽ | - | chat: script buffer | wählt einen Eintrag im Script-Buffer aus. | `/script go ${_chat_line_y}`
| ◽◽ | - | chat: script buffer | installiert/entfernt ein Skript. | `/script go ${_chat_line_y};/script installremove -q ${script_name_with_extension}`
| ◾◽◽ | up / left | buflist | verschiebt Buffer in der Reihenfolge nach unten. | Signal `buflist_mouse`.
| ◾◽◽ | down / right | buflist | verschiebt Buffer in der Reihenfolge nach oben. | Signal `buflist_mouse`.
| ◾◽◽ | - | buflist | wechselt zum Buffer (oder zum vorherigen Buffer, falls der aktuell genutzte Buffer angewählt wurde). | Signal `buflist_mouse`.
| ◽◽ | - | buflist | wechselt zum nächsten Buffer, falls der aktuell genutzte Buffer angewählt wurde. | Signal `buflist_mouse`.
| kbd:[Ctrl+▲] | - | buflist | wechselt zum vorherigen Buffer. | Signal `buflist_mouse`.
| kbd:[Ctrl+▼] | - | buflist | wechselt zum nächsten Buffer. | Signal `buflist_mouse`.
| ◾◽◽ | hoch | Benutzerliste | Benutzerliste um eine Seite nach oben blättern. | `/bar scroll nicklist ${_window_number} -100%`
| ◽◽ | runter | Benutzerliste | Benutzerliste um eine Seite nach unten blättern. | `/bar scroll nicklist ${_window_number} +100%`
| ◽◽ | hoch(lang) | Benutzerliste | springt zum Anfang der Benutzerliste. | `/bar scroll nicklist ${_window_number} b`
| ◾◽◽ | runter(lang) | Benutzerliste | springt zum Ende der Benutzerliste. | `/bar scroll nicklist ${_window_number} e`
| ◾◽◽ | - | Benutzerliste | öffnet privaten Chat mit Nick. | `/window ${_window_number};/query ${nick}`
| ◽◽ | - | Benutzerliste | führt einen whois für Nick aus. | `/window ${_window_number};/whois ${nick}`
| ◾◽◽ | links | Benutzerliste | kickt Nick. | `/window ${_window_number};/kick ${nick}`
| ◾◽◽ | links(lang) | Benutzerliste | kickt und verbannt Nick. | `/window ${_window_number};/kickban ${nick}`
| ◽◽◾ | links | Benutzerliste | verbannt Nick. | `/window ${_window_number};/ban ${nick}`
| ◽◽◾ | - | Input | fängt ein Mausereignis und fügt dieses in die Befehlszeile ein. | `/input grab_mouse_area`
| kbd:[▲] | - | jede Bar | blättert Bar um 20% nach oben. | `/bar scroll ${_bar_name} ${_window_number} -20%`
| kbd:[▼] | - | jede Bar | blättert Bar um 20% nach unten. | `/bar scroll ${_bar_name} ${_window_number} +20%`
| ◽◾◽ | - | überall | aktiviert den Cursor-Modus an dieser Position. | `/cursor go ${_x},${_y}`
|===
[NOTE]
^(1)^ kbd:[▲] und kbd:[▼] sind Symbole für Mausrad hoch/runter.
[[key_bindings_fset_buffer]]
==== Tasten für den fset Buffer
Diese Tasten und Aktionen werden im fset-Buffer verwendet (siehe <<fset_plugin,Fset Erweiterung>>).
[width="100%",cols="^.^3,^.^2,.^8,.^5",options="header"]
|===
| Taste | Action ^(1)^ | Beschreibung | Befehl
| kbd:[↑] | | einen Eintrag nach oben. | `/fset -up`
| kbd:[↓] | | einen Eintrag nach unten. | `/fset -down`
| kbd:[PgUp] | | eine Seite hoch blättern. | `/window page_up`
| kbd:[PgDn] | | eine Seite runter blättern. | `/window page_down`
| kbd:[Alt+Home] | `pass:[<<]` | springt zum ersten Eintrag. | `/fset -go 0`
| kbd:[Alt+End] | `pass:[>>]` | springt zum letzten Eintrag. | `/fset -go end`
| kbd:[F11] | `pass:[<]` | scrollt horizontal nach links. | `/fset -left`
| kbd:[F12] | `pass:[>]` | scrollt horizontal nach rechts. | `/fset -right`
| kbd:[Alt+Space] | `t` | Boolean Wert ein/ausschalten. | `/fset -toggle`
| kbd:[Alt+-] | `-` | subtrahiert 1 vom Wert bei Integer/Farboptionen, bei anderen Typen kann der Wert editiert werden. | `/fset -add -1`
| kbd:[Alt++] | `+` | addiert 1 zum Wert bei Integer/Farboptionen, bei anderen Typen kann der Wert editiert werden. | `/fset -add 1`
| kbd:[Alt+f],
kbd:[Alt+r] | `r` | Wert resetten. | `/fset -reset`
| kbd:[Alt+f],
kbd:[Alt+u] | `u` | Wert zurücksetzen. | `/fset -unset`
| kbd:[Alt+Enter] | `s` | Wert setzen. | `/fset -set`
| kbd:[Alt+f],
kbd:[Alt+n] | `n` | ein neuer Wert wird gesetzt, der alte Wert wird gelöscht. | `/fset -setnew`
| kbd:[Alt+f],
kbd:[Alt+a] | `a` | dem Wert was hinzufügen. | `/fset -append`
| kbd:[Alt+,] | `,` | markieren/demarkieren einer Option. | `/fset -mark 1`
| kbd:[Shift+↑] | | eine Zeile nach oben und markiert/demarkiert Option. | `/fset -up; /fset -mark`
| kbd:[Shift+↓] | | markiert/demarkiert Option und geht eine Zeile nach unten. | `/fset -mark; /fset -down`
| | `m:xxx` | markiert Optionen welche angezeigt werden und auf die der Filter "xxx" zutrifft (jeder Filter für Option oder Wert ist erlaubt, siehe <<command_fset_fset,fset command>>). |
| | `u:xxx` | demarkiert Optionen welche angezeigt werden und auf die der Filter "xxx" zutrifft (jeder Filter für Option oder Wert ist erlaubt, siehe <<command_fset_fset,fset command>>). |
| kbd:[Ctrl+l] (`L`) | | der Bildschirm wird neu gezeichnet. | `/fset -refresh`
| | `$` | Optionen neu einlesen (markierte Optionen werden beibehalten). |
| | `$$` | Optionen neu einlesen (Markierungen von Optionen werden dabei gelöscht). |
| kbd:[Alt+p] | | Umschalten der Beschreibung von Erweiterungen (`pass:[plugins.desc.*]`). | `/mute /set fset.look.show_plugins_desc toggle`
| kbd:[Alt+v] | | Hilfe-Bar Ein-/Ausschalten. | `/bar toggle fset`
| | `s:x,y` | sortiert Optionen nach Bereichen x,y (siehe Option <<option_fset.look.sort,fset.look.sort>>). | `/mute /set fset.look.sort x,y`
| | `s:` | setzt Sortierung wieder auf Standardwerte (siehe Option <<option_fset.look.sort,fset.look.sort>>). | `/mute /unset fset.look.sort`
| | `w:xxx` | exportiert Optionen in Datei "xxx". | `/fset -export xxx`
| | `w-:xxx` | exportiert Optionen in Datei "xxx", ohne Hilfstext. | `/fset -export -nohelp xxx`
| | `w+:xxx` | exportiert Optionen in Datei "xxx", mit Hilfstext. | `/fset -export -help xxx`
| kbd:[Ctrl+x] | `x` | Umschalten zwischen der Darstellung von Optionen. | `/fset -format`
| | `q` | fset Buffer schließen. | `/buffer close`
|===
[NOTE]
^(1)^ Die Aktion muss als Eingabe in die Befehlszeile eingegeben werden, gefolgt von kbd:[Enter].
[[key_bindings_script_buffer]]
==== Tasten für Skript Buffer
Diese Tasten und Aktionen werden im fset-Buffer verwendet (siehe <<scripts_plugins,Skript Erweiterung>>).
[width="100%",cols="^.^3,^.^2,.^8,.^5",options="header"]
|===
| Taste | Action ^(1)^ | Beschreibung | Befehl
| kbd:[↑] | | eine Zeile nach oben. | `/script up`
| kbd:[↓] | | eine Zeile nach unten. | `/script down`
| kbd:[PgUp] | | eine Seite hoch blättern. | `/window page_up`
| kbd:[PgDn] | | eine Seite nach unten blättern. | `/window page_down`
| kbd:[Alt+i] | `i` | Skript installieren. | `/script install`
| kbd:[Alt+r] | `r` | Skript entfernen. | `/script remove`
| kbd:[Alt+l] (`L`) | `l` | Skript laden. | `/script load`
| kbd:[Alt+u] | `u` | Skript wird beendet. | `/script unload`
| kbd:[Alt+Shift+A] | `A` | das Skript wird in das autoload-Verzeichnis eingebunden. | `/script toggleautoload`
| kbd:[Alt+h] | `h` | Skript wird gehalten bzw. freigegeben. | `/script hold`
| kbd:[Alt+v] | `v` | Skript Quelltext anzeigen. | `/script show`
|===
[NOTE]
^(1)^ Die Aktion muss als Eingabe in die Befehlszeile eingegeben werden, gefolgt von kbd:[Enter].
[[mouse]]
=== Mausunterstützung
@@ -2130,9 +2220,16 @@ Dem gegenüber ist ein _Skript_ eine Textdatei die durch eine Erweiterung z.B. _
mittels dem Befehl `/python` geladen wird.
Mit dem Befehl `/plugin` kann eine Erweiterung geladen bzw. entfernt werden. Auch können
mit dem Befehl alle installierten Erweiterungen aufgelistet werden. Wird eine Erweiterung
entfernt hat dies Einfluss auf die von dieser Erweiterung geöffneten Buffer.
Diese Buffer werden dann geschlossen.
mit dem Befehl alle installierten Erweiterungen aufgelistet werden.
Sobald eine Erweiterung beendet wird, entfernt WeeChat:
* Buffer
* Konfigurationsoptionen (Optionen die in Datein geschrieben wurden)
* alle Hooks: commands, modifiers, process, etc.
* Infos und Infolisten
* hdata
* Bar-Items.
Beispiele wie man Erweiterungen lädt, entfernt und auflistet:
@@ -3022,12 +3119,16 @@ weitere Beispiele:
==== Dateinamenmaske
Es ist möglich eine Dateinamenmaske für jeden Buffer zu erstellen und diese Maske
mit lokalen Buffervariablen zu füllen. Um zu sehen welche lokalen Variabel es gibt:
mit lokalen Buffervariablen zu füllen. Um sich die verfügbaren lokalen Variablen
für den aktuellen Buffer anzeigen zu lassen:
----
/buffer localvar
----
Masken werden in absteigender Reihenfolge abgeglichen, beginnend mit
`logger.mask.$plugin.*`, dabei fungiert `logger.file.mask` als Fallback-Option.
Zum Beispiel für den Buffer "irc.freenode.#weechat". WeeChat sucht in dieser
Reihenfolge nach einer Maske:
@@ -4106,7 +4207,7 @@ Der Callback von "line" legt folgende Variablen in der Hashtable an:
| str_time | string | Datum für Darstellung. Kann Farbkodierungen erhalten.
| tags | string | Tags einer Nachricht (Komma wird automatisch zu Beginn und Ende den Tags hinzugefügt).
| displayed | string | "1" wenn Zeile dargestellt wird, "0" wenn Zeile gefiltert wird.
| notify_level | string | "0" = low level, "1" = Nachricht, "2" = private Nachricht, "3" = Highlight
| notify_level | string | "-1" = keine Benachrichtigung, "0" = niedrige Stufe, "1" = Nachricht, "2" = private Nachricht, "3" = Highlight
| highlight | string | "1" wenn Highlight, andernfalls "0".
| prefix | string | Prefix.
| tg_prefix_nocolor | string | Prefix, ohne Farbkodierung.
+68 -68
View File
@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright (C) 2008-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2008-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -17,27 +17,33 @@
#
"""
Documentation generator for WeeChat: build include files with commands,
options, infos, infolists, hdata and completions for WeeChat core and
plugins.
Documentation generator for WeeChat: build include files with:
Instructions to build config files yourself in WeeChat directories (replace
all paths with your path to WeeChat):
1. run WeeChat and load this script, with following command:
/python load ~/src/weechat/doc/docgen.py
2. change path to build in your doc/ directory:
/set plugins.var.python.docgen.path "~/src/weechat/doc"
3. run docgen command:
/docgen
Note: it is recommended to load only this script when building doc.
Files should be in ~/src/weechat/doc/xx/autogen/ (where xx is language).
- commands
- config options
- default aliases
- IRC colors
- infos
- infos hashtable
- infolists
- hdata
- completions
- URL options
- plugins priority.
Instructions to build config files yourself in WeeChat directories
(replace "path" with the path to the docgen.py script in WeeChat repository):
weechat -t -r "/python load /path/docgen.py;/docgen;/quit"
Output files are in /path/xx/autogen/ (where xx is language).
"""
from __future__ import print_function
SCRIPT_NAME = 'docgen'
SCRIPT_AUTHOR = 'Sébastien Helleu <flashcode@flashtux.org>'
SCRIPT_VERSION = '0.1'
SCRIPT_VERSION = '0.2'
SCRIPT_LICENSE = 'GPL3'
SCRIPT_DESC = 'Documentation generator for WeeChat'
@@ -51,7 +57,6 @@ try:
import hashlib
import os
import re
import sys
from collections import defaultdict
from operator import itemgetter
except ImportError as message:
@@ -65,19 +70,15 @@ except ImportError:
print('Get WeeChat now at: https://weechat.org/')
IMPORT_OK = False
# default path where doc files will be written (should be doc/ in sources
# package tree)
# path must have subdirectories with languages and autogen directory:
# path
# |-- en
# | |-- autogen
# |-- fr
# | |-- autogen
# ...
DEFAULT_PATH = '~/src/weechat/doc'
# list of locales for which we want to build doc files to include
LOCALE_LIST = ('en_US', 'fr_FR', 'it_IT', 'de_DE', 'ja_JP', 'pl_PL')
LOCALE_LIST = (
'de_DE',
'en_US',
'fr_FR',
'it_IT',
'ja_JP',
'pl_PL',
)
# all commands/options/.. of following plugins will produce a file
# non-listed plugins will be ignored
@@ -120,7 +121,6 @@ IGNORE_OPTIONS = (
r'irc\.ctcp\..*',
r'irc\.ignore\..*',
r'irc\.server\..*',
r'jabber\.server\..*',
r'logger\.level\..*',
r'logger\.mask\..*',
r'relay\.port\..*',
@@ -137,11 +137,19 @@ IGNORE_OPTIONS = (
# completions to ignore
IGNORE_COMPLETIONS_ITEMS = (
'docgen.*',
'jabber.*',
'weeget.*',
)
def sha256_file(filename, default=None):
"""Return SHA256 checksum of a file."""
try:
with open(filename, 'rb') as _file:
checksum = hashlib.sha256(_file.read()).hexdigest()
except IOError:
checksum = default
return checksum
class AutogenDoc(object):
"""A class to write auto-generated doc files."""
@@ -159,29 +167,14 @@ class AutogenDoc(object):
"""Write a line in auto-generated doc file."""
self._file.write(string)
@staticmethod
def sha256_file(filename, default):
"""
Return SHA256 checksum of a file, "default" if file is not found.
"""
try:
with open(filename, 'r') as _file:
content = _file.read()
if sys.version_info >= (3, ):
content = content.encode('utf-8')
checksum = hashlib.sha256(content).hexdigest()
except IOError:
checksum = default
return checksum
def update(self, obj_name, num_files, num_files_updated):
"""Update doc file if needed (if content has changed)."""
# close temp file
self._file.close()
shaold = AutogenDoc.sha256_file(self.filename, 'old')
shanew = AutogenDoc.sha256_file(self.filename_tmp, 'new')
sha_old = sha256_file(self.filename, 'old')
sha_new = sha256_file(self.filename_tmp, 'new')
# compare checksums
if shaold != shanew:
if sha_old != sha_new:
# update doc file
if os.path.exists(self.filename):
os.unlink(self.filename)
@@ -450,6 +443,15 @@ def get_plugins_priority():
return plugins_priority
def print_counters(label, files, updated):
"""Print a line with counters."""
color = weechat.color('*lightred') if updated > 0 else ''
weechat.prnt('',
'docgen: {0}: {1} files, {2}{3}{4} updated'
''.format(label, files, color, updated,
weechat.color('reset')))
# pylint: disable=too-many-locals, too-many-branches, too-many-statements
# pylint: disable=too-many-nested-blocks
def docgen_cmd_cb(data, buf, args):
@@ -457,7 +459,7 @@ def docgen_cmd_cb(data, buf, args):
if args:
locales = args.split(' ')
else:
locales = LOCALE_LIST
locales = sorted(LOCALE_LIST)
commands = get_commands()
options = get_options()
infos = get_infos()
@@ -470,11 +472,6 @@ def docgen_cmd_cb(data, buf, args):
irc_colors = get_irc_colors()
plugins_priority = get_plugins_priority()
# get path and replace ~ by home if needed
path = weechat.config_get_plugin('path')
if path.startswith('~'):
path = os.environ['HOME'] + path[1:]
# write to doc files, by locale
num_files = defaultdict(int)
num_files_updated = defaultdict(int)
@@ -483,6 +480,8 @@ def docgen_cmd_cb(data, buf, args):
translate = lambda s: (s and _(s)) or s
escape = lambda s: s.replace('|', '\\|')
weechat.prnt('', '-' * 40)
for locale in locales:
for key in num_files:
if key != 'total2':
@@ -493,7 +492,9 @@ def docgen_cmd_cb(data, buf, args):
languages=[locale + '.UTF-8'],
fallback=True)
trans.install()
directory = path + '/' + locale[0:2] + '/autogen'
directory = os.path.join(os.path.dirname(data),
locale[0:2],
'autogen')
if not os.path.isdir(directory):
weechat.prnt('',
'{0}docgen error: directory "{1}" does not exist'
@@ -721,7 +722,7 @@ def docgen_cmd_cb(data, buf, args):
doc.write('|===\n')
doc.update('completions', num_files, num_files_updated)
# write url options
# write URL options
doc = AutogenDoc(directory, 'plugin_api', 'url_options')
doc.write('[width="100%",cols="2,^1,7",options="header"]\n')
doc.write('|===\n')
@@ -748,14 +749,15 @@ def docgen_cmd_cb(data, buf, args):
doc.update('plugins_priority', num_files, num_files_updated)
# write counters
weechat.prnt('',
'docgen: {0}: {1} files, {2} updated'
''.format(locale,
num_files['total1'],
num_files_updated['total1']))
weechat.prnt('',
'docgen: total: {0} files, {1} updated'
''.format(num_files['total2'], num_files_updated['total2']))
print_counters(locale, num_files['total1'],
num_files_updated['total1'])
weechat.prnt('', ' -' * 20)
print_counters('total', num_files['total2'], num_files_updated['total2'])
weechat.prnt('', '-' * 40)
return weechat.WEECHAT_RC_OK
@@ -776,8 +778,6 @@ if __name__ == '__main__' and IMPORT_OK:
'locales: list of locales to build (by default '
'build all locales)',
'%(docgen_locales)|%*',
'docgen_cmd_cb', '')
'docgen_cmd_cb', __file__)
weechat.hook_completion('docgen_locales', 'locales for docgen',
'docgen_completion_cb', '')
if not weechat.config_is_set_plugin('path'):
weechat.config_set_plugin('path', DEFAULT_PATH)
+1 -2
View File
@@ -1,6 +1,6 @@
<!--
Custom styles for Asciidoctor
Copyright (C) 2016-2019 Sébastien Helleu <flashcode@flashtux.org>
Copyright (C) 2016-2020 Sébastien Helleu <flashcode@flashtux.org>
-->
<style>
#header,#content,#footnotes,#footer {
@@ -17,7 +17,6 @@ h1,h2,h3,h4,h5 {
.literalblock pre {
font-family: monospace, 'Courier New', Courier;
line-height: normal;
font-size: .95em;
}
kbd {
font-size: .9em;
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2006 Julien Louis <ptitlouis@sysif.net>
#
# This file is part of WeeChat, the extensible chat client.
+3 -1
View File
@@ -38,6 +38,8 @@
| irc | irc_privates | privates on all IRC servers
| irc | irc_raw_filters | filters for irc raw buffer
| irc | irc_server | current IRC server
| irc | irc_server_channels | channels on current IRC server
@@ -142,7 +144,7 @@
| weechat | env_vars | environment variables
| weechat | filename | filename
| weechat | filename | filename; optional argument: default path (evaluated, see /help eval)
| weechat | filters_names | names of filters
+2
View File
@@ -213,6 +213,7 @@ _last_irc_server_ +
| _name_   (string) +
_options_   (pointer) +
_temp_server_   (integer) +
_fake_server_   (integer) +
_reloading_from_config_   (integer) +
_reloaded_from_config_   (integer) +
_addresses_eval_   (string) +
@@ -546,6 +547,7 @@ _layout_number_   (integer) +
_layout_number_merge_order_   (integer) +
_name_   (string) +
_full_name_   (string) +
_old_full_name_   (string) +
_short_name_   (string) +
_type_   (integer) +
_notify_   (integer) +
+4
View File
@@ -80,6 +80,8 @@
| tcl | tcl_version | version of the interpreter used | -
| weechat | auto_connect | 1 if automatic connection to servers is enabled, 0 if it has been disabled by the user (option "-a" or "--no-connect") | -
| weechat | charset_internal | WeeChat internal charset | -
| weechat | charset_terminal | terminal charset | -
@@ -130,6 +132,8 @@
| weechat | weechat_dir | WeeChat directory | -
| weechat | weechat_headless | 1 if WeeChat is running headless | -
| weechat | weechat_libdir | WeeChat "lib" directory | -
| weechat | weechat_localedir | WeeChat "locale" directory | -
@@ -6,7 +6,7 @@
|===
| Plugin | Name | Description | Hashtable (input) | Hashtable (output)
| irc | irc_message_parse | parse an IRC message | "message": IRC message, "server": server name (optional) | "tags": tags, "message_without_tags": message without the tags, "nick": nick, "host": host, "command": command, "channel": channel, "arguments": arguments (includes channel), "text": text (for example user message), "pos_command": index of "command" message ("-1" if "command" was not found), "pos_arguments": index of "arguments" message ("-1" if "arguments" was not found), "pos_channel": index of "channel" message ("-1" if "channel" was not found), "pos_text": index of "text" message ("-1" if "text" was not found)
| irc | irc_message_parse | parse an IRC message | "message": IRC message, "server": server name (optional) | "tags": tags, "message_without_tags": message without the tags, "nick": nick, "user": user, "host": host, "command": command, "channel": channel, "arguments": arguments (includes channel), "text": text (for example user message), "pos_command": index of "command" message ("-1" if "command" was not found), "pos_arguments": index of "arguments" message ("-1" if "arguments" was not found), "pos_channel": index of "channel" message ("-1" if "channel" was not found), "pos_text": index of "text" message ("-1" if "text" was not found)
| irc | irc_message_split | split an IRC message (to fit in 512 bytes by default) | "message": IRC message, "server": server name (optional) | "msg1" ... "msgN": messages to send (without final "\r\n"), "args1" ... "argsN": arguments of messages, "count": number of messages
@@ -20,6 +20,9 @@ The lines with buffers are displayed using string evaluation (see /help eval for
The following variables can be used in these options:
- bar item data (see hdata "bar_item" in API doc for a complete list), for example:
- ${bar_item.name}
- window data, where the bar item is displayed (there's no window in root bars, see hdata "window" in API doc for a complete list), for example:
- ${window.number}
- ${window.buffer.full_name}
- buffer data (see hdata "buffer" in API doc for a complete list), for example:
- ${buffer.number}
- ${buffer.name}
+13 -2
View File
@@ -373,7 +373,7 @@ reason: reason
----
[[command_irc_links]]
* `+links+`: list all servernames which are known by the server answering the query
* `+links+`: list all server names which are known by the server answering the query
----
/links [[<target>] <server_mask>]
@@ -726,7 +726,8 @@ reason: reason
reorder <name> [<name>...]
open <name>|-all [<name>...]
del|keep <name>
deloutq|jump|raw
deloutq|jump
raw [<filter>]
list: list servers (without argument, this list is displayed)
listfull: list servers with detailed info for each server
@@ -745,6 +746,13 @@ nooption: set boolean option to 'off' (for example: -nossl)
deloutq: delete messages out queue for all servers (all messages WeeChat is currently sending)
jump: jump to server buffer
raw: open buffer with raw IRC data
filter: set a new filter to see only matching messages (this filter can be used as input in raw IRC data buffer as well); allowed formats are:
* show all messages (no filter)
xxx show only messages containing "xxx"
s:xxx show only messages for server "xxx"
f:xxx show only messages with a flag: recv (message received), sent (message sent), modified (message modified by a modifier), redirected (message redirected)
m:xxx show only IRC command "xxx"
c:xxx show only messages matching the evaluated condition "xxx", using following variables: output of function irc_message_parse (like nick, command, channel, text, etc., see function info_get_hashtable in plugin API reference for the list of all variables), date (format: "yyyy-mm-dd hh:mm:ss"), server, recv, sent, modified, redirected
Examples:
/server listfull
@@ -756,6 +764,9 @@ Examples:
/server reorder freenode2 freenode
/server del freenode
/server deloutq
/server raw
/server raw s:freenode
/server raw c:${recv} && ${command}==PRIVMSG && ${nick}==foo
----
[[command_irc_service]]
+31 -7
View File
@@ -44,6 +44,12 @@
** values: a WeeChat color name (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), a terminal color number or an alias; attributes are allowed before color (for text color only, not background): "*" for bold, "!" for reverse, "/" for italic, "_" for underline
** default value: `+green+`
* [[option_irc.color.message_kick]] *irc.color.message_kick*
** description: pass:none[color for text in kick/kill messages]
** type: color
** values: a WeeChat color name (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), a terminal color number or an alias; attributes are allowed before color (for text color only, not background): "*" for bold, "!" for reverse, "/" for italic, "_" for underline
** default value: `+red+`
* [[option_irc.color.message_quit]] *irc.color.message_quit*
** description: pass:none[color for text in part/quit messages]
** type: color
@@ -68,6 +74,12 @@
** values: a WeeChat color name (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), a terminal color number or an alias; attributes are allowed before color (for text color only, not background): "*" for bold, "!" for reverse, "/" for italic, "_" for underline
** default value: `+green+`
* [[option_irc.color.reason_kick]] *irc.color.reason_kick*
** description: pass:none[color for reason in kick/kill messages]
** type: color
** values: a WeeChat color name (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), a terminal color number or an alias; attributes are allowed before color (for text color only, not background): "*" for bold, "!" for reverse, "/" for italic, "_" for underline
** default value: `+default+`
* [[option_irc.color.reason_quit]] *irc.color.reason_quit*
** description: pass:none[color for reason in part/quit messages]
** type: color
@@ -212,6 +224,12 @@
** values: on, off
** default value: `+on+`
* [[option_irc.look.display_pv_warning_address]] *irc.look.display_pv_warning_address*
** description: pass:none[display a warning in private buffer if the address of remote nick has changed; this option is disabled by default because servers like bitlbee are causing this warning to be displayed when it is not expected (the address of remote nick changes multiple times on login)]
** type: boolean
** values: on, off
** default value: `+off+`
* [[option_irc.look.highlight_channel]] *irc.look.highlight_channel*
** description: pass:none[comma separated list of words to highlight in channel buffers (case insensitive, use "(?-i)" at beginning of words to make them case sensitive; special variables $nick, $channel and $server are replaced by their value), these words are added to buffer property "highlight_words" only when buffer is created (it does not affect current buffers), an empty string disables default highlight on nick, examples: "$nick", "(?-i)$nick"]
** type: string
@@ -369,7 +387,7 @@
** default value: `+merge_with_core+`
* [[option_irc.look.smart_filter]] *irc.look.smart_filter*
** description: pass:none[filter join/part/quit/nick messages for a nick if not speaking for some minutes on channel (you must create a filter on tag "irc_smart_filter")]
** description: pass:none[filter join/part/quit/nick messages for a nick if not speaking for some minutes on channel (you must create a filter on tag "irc_smart_filter", see /help filter)]
** type: boolean
** values: on, off
** default value: `+on+`
@@ -446,12 +464,6 @@
** values: any string
** default value: `+"*!$ident@$host"+`
* [[option_irc.network.channel_encode]] *irc.network.channel_encode*
** description: pass:none[decode/encode channel name inside messages using charset options; it is recommended to keep that off if you use only UTF-8 in channel names; you can enable this option if you are using an exotic charset like ISO in channel names]
** type: boolean
** values: on, off
** default value: `+off+`
* [[option_irc.network.colors_receive]] *irc.network.colors_receive*
** description: pass:none[when off, colors codes are ignored in incoming messages]
** type: boolean
@@ -596,6 +608,12 @@
** values: any string
** default value: `+""+`
* [[option_irc.server_default.charset_message]] *irc.server_default.charset_message*
** description: pass:none[part of the IRC message (received or sent) which is decoded/encoded to the target charset; message = the whole IRC message (default), channel = starting from the channel name only (if found, with fallback on text), text = starting from the text only (you should try this value if you have issues with the channel name encoding)]
** type: integer
** values: message, channel, text
** default value: `+message+`
* [[option_irc.server_default.command]] *irc.server_default.command*
** description: pass:none[command(s) to run after connection to server and before auto-join of channels (many commands can be separated by ";", use "\;" for a semicolon, special variables $nick, $channel and $server are replaced by their value) (note: content is evaluated, see /help eval; server options are evaluated with ${irc_server.xxx} and ${server} is replaced by the server name)]
** type: string
@@ -746,6 +764,12 @@
** values: any string
** default value: `+""+`
* [[option_irc.server_default.ssl_password]] *irc.server_default.ssl_password*
** description: pass:none[password for SSL certificate's private key; only used with gnutls version >= 3.1.0 (note: content is evaluated, see /help eval; server options are evaluated with ${irc_server.xxx} and ${server} is replaced by the server name)]
** type: string
** values: any string
** default value: `+""+`
* [[option_irc.server_default.ssl_priorities]] *irc.server_default.ssl_priorities*
** description: pass:none[string with priorities for gnutls (for syntax, see documentation of function gnutls_priority_init in gnutls manual, common strings are: "PERFORMANCE", "NORMAL", "SECURE128", "SECURE256", "EXPORT", "NONE")]
** type: string
+7 -1
View File
@@ -9,7 +9,7 @@
** default value: `+default+`
* [[option_logger.color.backlog_line]] *logger.color.backlog_line*
** description: pass:none[color for backlog lines]
** description: pass:none[color for backlog lines, used only if the option logger.file.color_lines is off]
** type: color
** values: a WeeChat color name (default, black, (dark)gray, white, (light)red, (light)green, brown, yellow, (light)blue, (light)magenta, (light)cyan), a terminal color number or an alias; attributes are allowed before color (for text color only, not background): "*" for bold, "!" for reverse, "/" for italic, "_" for underline
** default value: `+default+`
@@ -20,6 +20,12 @@
** values: on, off
** default value: `+on+`
* [[option_logger.file.color_lines]] *logger.file.color_lines*
** description: pass:none[use ANSI color codes in lines written in log files and display backlog lines with these colors]
** type: boolean
** values: on, off
** default value: `+off+`
* [[option_logger.file.flush_delay]] *logger.file.flush_delay*
** description: pass:none[number of seconds between flush of log files (0 = write in log files immediately for each line printed)]
** type: integer
+5 -3
View File
@@ -6,7 +6,7 @@
* `+script+`: WeeChat script manager
----
/script list [-o|-i]
/script list [-o|-ol|-i|-il]
search <text>
show <script>
load|unload|reload <script> [<script>...]
@@ -16,8 +16,10 @@
update
list: list loaded scripts (all languages)
-o: send list of loaded scripts to buffer
-i: copy list of loaded scripts in command line (for sending to buffer)
-o: send list of loaded scripts to buffer (string in English)
-ol: send list of loaded scripts to buffer (translated string)
-i: copy list of loaded scripts in command line (for sending to buffer) (string in English)
-il: copy list of loaded scripts in command line (for sending to buffer) (translated string)
search: search scripts by tags, language (python, perl, ...), filename extension (py, pl, ...) or text; result is displayed on scripts buffer
show: show detailed info about a script
load: load script(s)
+19 -13
View File
@@ -263,11 +263,12 @@ infolists: display infos about infolists
* `+eval+`: evaluate expression
----
/eval [-n|-s] <expression>
[-n] -c <expression1> <operator> <expression2>
/eval [-n|-s] [-d] <expression>
[-n] [-d] -c <expression1> <operator> <expression2>
-n: display result without sending it to buffer (debug mode)
-s: split expression before evaluating it (many commands can be separated by semicolons)
-d: display debug output after evaluation
-c: evaluate as condition: use operators and parentheses, return a boolean value ("0" or "1")
expression: expression to evaluate, variables with format ${variable} are replaced (see below); many commands can be separated by semicolons
operator: a logical or comparison operator:
@@ -301,16 +302,19 @@ Some variables are replaced in expression, using the format ${variable}, variabl
3. a string with chars to hide (format: "hide:char,string")
4. a string with max chars (format: "cut:max,suffix,string" or "cut:+max,suffix,string")
or max chars displayed on screen (format: "cutscr:max,suffix,string" or "cutscr:+max,suffix,string")
5. a reversed string (format: "rev:xxx")
5. a reversed string (format: "rev:xxx" or "revscr:xxx")
6. a repeated string (format: "repeat:count,string")
7. a color (format: "color:xxx", see "Plugin API reference", function "color")
8. an info (format: "info:name,arguments", arguments are optional)
9. current date/time (format: "date" or "date:format")
10. an environment variable (format: "env:XXX")
11. a ternary operator (format: "if:condition?value_if_true:value_if_false")
12. an option (format: "file.section.option")
13. a local variable in buffer
14. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
7. length of a string (format: "length:xxx" or "lengthscr:xxx")
8. a color (format: "color:xxx", see "Plugin API reference", function "color")
9. a modifier (format: "modifier:name,data,string")
10. an info (format: "info:name,arguments", arguments are optional)
11. current date/time (format: "date" or "date:format")
12. an environment variable (format: "env:XXX")
13. a ternary operator (format: "if:condition?value_if_true:value_if_false")
14. result of an expression with parentheses and operators + - * / // % ** (format: "calc:xxx")
15. an option (format: "file.section.option")
16. a local variable in buffer
17. a hdata name/variable (the value is automatically converted to string), by default "window" and "buffer" point to current window/buffer.
Format for hdata can be one of following:
hdata.var1.var2...: start with a hdata (pointer must be known), and ask variables one after one (other hdata can be followed)
hdata[list].var1.var2...: start with a hdata using a list, for example:
@@ -337,6 +341,8 @@ Examples (simple strings):
/eval -n ${if:${info:term_width}>80?big:small} ==> big
/eval -n ${rev:Hello} ==> olleH
/eval -n ${repeat:5,-} ==> -----
/eval -n ${length:test} ==> 4
/eval -n ${calc:(5+2)*3} ==> 21
Examples (conditions):
/eval -n -c ${window.buffer.number} > 2 ==> 0
@@ -925,7 +931,7 @@ It is possible to restore WeeChat session on another machine if you copy the con
* `+uptime+`: show WeeChat uptime
----
/uptime [-o | -ol]
/uptime [-o|-ol]
-o: send uptime to current buffer as input (English string)
-ol: send uptime to current buffer as input (translated string)
@@ -935,7 +941,7 @@ It is possible to restore WeeChat session on another machine if you copy the con
* `+version+`: show WeeChat version and compilation date
----
/version [-o | -ol]
/version [-o|-ol]
-o: send version to current buffer as input (English string)
-ol: send version to current buffer as input (translated string)
+7 -1
View File
@@ -915,7 +915,7 @@
** default value: `+100+`
* [[option_weechat.look.nick_color_force]] *weechat.look.nick_color_force*
** description: pass:none[force color for some nicks: hash computed with nickname to find color will not be used for these nicks (format is: "nick1:color1;nick2:color2"); look up for nicks is with exact case then lower case, so it's possible to use only lower case for nicks in this option]
** description: pass:none[force color for some nicks: hash computed with nickname to find color will not be used for these nicks (format is: "nick1:color1;nick2:color2"); look up for nicks is with exact case then lower case, so it's possible to use only lower case for nicks in this option; color can include background with the format "text,background", for example "yellow,red"]
** type: string
** values: any string
** default value: `+""+`
@@ -926,6 +926,12 @@
** values: djb2, sum, djb2_32, sum_32
** default value: `+djb2+`
* [[option_weechat.look.nick_color_hash_salt]] *weechat.look.nick_color_hash_salt*
** description: pass:none[salt for the hash algorithm used to find nick colors (the nickname is appended to this salt and the hash algorithm operates on this string); modifying this shuffles nick colors]
** type: string
** values: any string
** default value: `+""+`
* [[option_weechat.look.nick_color_stop_chars]] *weechat.look.nick_color_stop_chars*
** description: pass:none[chars used to stop in nick when computing color with letters of nick (at least one char outside this list must be in string before stopping) (example: nick "|nick|away" with "|" in chars will return color of nick "|nick"); this option has an impact on option weechat.look.nick_color_force, so the nick for the forced color must not contain the chars ignored by this option]
** type: string
+6
View File
@@ -104,6 +104,12 @@
** values: any string
** default value: `+"%h/xfer"+`
* [[option_xfer.file.download_temporary_suffix]] *xfer.file.download_temporary_suffix*
** description: pass:none[temporary filename suffix used during the transfer for a file received, it is removed after successful transfer; if empty string, no filename suffix is used during the transfer]
** type: string
** values: any string
** default value: `+".part"+`
* [[option_xfer.file.upload_path]] *xfer.file.upload_path*
** description: pass:none[path for reading files when sending (when no path is specified by user): "%h" at beginning of string is replaced by WeeChat home ("~/.weechat" by default) (note: content is evaluated, see /help eval)]
** type: string
+1 -1
View File
@@ -1,7 +1,7 @@
WeeChat is written by Sébastien Helleu and contributors (complete list is in
the AUTHORS.adoc file).
Copyright (C) 2003-2019 {author}
Copyright (C) 2003-2020 {author}
WeeChat is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
+53 -44
View File
@@ -58,7 +58,7 @@ This manual documents only _weechat_ repository.
The main WeeChat directories are:
[width="100%",cols="1m,3",options="header"]
[width="100%",cols="1m,2",options="header"]
|===
| Directory | Description
| src/ | Root of sources.
@@ -114,16 +114,18 @@ WeeChat "core" is located in following directories:
* _src/core/_: core functions (for data manipulation)
* _src/gui/_: functions about interface (buffers, windows, ...)
[width="100%",cols="1m,3",options="header"]
[width="100%",cols="1m,2",options="header"]
|===
| Path/file | Description
| core/ | Core functions: entry point, internal structures.
|    wee-arraylist.c | Array lists.
|    wee-backtrace.c | Display a backtrace after a crash.
|    wee-calc.c | Calculate result of expressions.
|    wee-command.c | WeeChat core commands.
|    wee-completion.c | Default completions.
|    wee-config-file.c | Configuration file management.
|    wee-config.c | Configuration options for WeeChat core (file weechat.conf).
|    wee-crypto.c | Cryptographic functions.
|    wee-debug.c | Some debug functions.
|    wee-eval.c | Evaluation of expressions with references to internal vars.
|    wee-hashtable.c | Hashtables.
@@ -205,7 +207,7 @@ WeeChat "core" is located in following directories:
[[sources_plugins]]
==== Plugins
[width="100%",cols="1m,3",options="header"]
[width="100%",cols="1m,2",options="header"]
|===
| Path/file | Description
| plugins/ | Root of plugins.
@@ -296,6 +298,7 @@ WeeChat "core" is located in following directories:
|       weechat-js-v8.cpp | JavaScript v8 functions.
|    logger/ | Logger plugin.
|       logger.c | Main logger functions.
|       logger-backlog.c | Logger backlog functions.
|       logger-buffer.c | Logger buffer list management.
|       logger-command.c | Logger commands.
|       logger-config.c | Logger config options (file logger.conf).
@@ -373,44 +376,50 @@ WeeChat "core" is located in following directories:
[[sources_tests]]
==== Tests
[width="100%",cols="1m,3",options="header"]
[width="100%",cols="1m,2",options="header"]
|===
| Path/file | Description
| tests/ | Root of tests.
|    tests.cpp | Program used to run all tests.
|    scripts/ | Root of scripting API tests.
|       test-scripts.cpp | Program used to run the scripting API tests.
|       python/ | Python scripts to generate and run the scripting API tests.
|          testapigen.py | Python script generating scripts in all languages to test the scripting API.
|          testapi.py | Python script with scripting API tests, used by script testapigen.py.
|          unparse.py | Convert Python code to other languages, used by script testapigen.py.
|    unit/ | Root of unit tests.
|       test-plugins.cpp | Tests: plugins.
|       core/ | Root of unit tests for core.
|          test-core-arraylist.cpp | Tests: arraylists.
|          test-core-eval.cpp | Tests: evaluation of expressions.
|          test-core-hashtble.cpp | Tests: hashtables.
|          test-core-hdata.cpp | Tests: hdata.
|          test-core-hook.cpp | Tests: hooks.
|          test-core-infolist.cpp | Tests: infolists.
|          test-core-list.cpp | Tests: lists.
|          test-core-secure.cpp | Tests: secured data.
|          test-core-string.cpp | Tests: strings.
|          test-core-url.cpp | Tests: URLs.
|          test-core-utf8.cpp | Tests: UTF-8.
|          test-core-util.cpp | Tests: utility functions.
|       gui/ | Root of unit tests for interfaces.
|          test-gui-line.cpp | Tests: lines.
|          test-gui-nick.cpp | Tests: nicks.
|       plugins/ | Root of unit tests for plugins.
|          irc/ | Root of unit tests for IRC plugin.
|             test-irc-color.cpp | Tests: IRC colors.
|             test-irc-config.cpp | Tests: IRC configuration.
|             test-irc-ignore.cpp | Tests: IRC ignores.
|             test-irc-message.cpp | Tests: IRC messages.
|             test-irc-mode.cpp | Tests: IRC modes.
|             test-irc-nick.cpp | Tests: IRC nicks.
|             test-irc-protocol.cpp | Tests: IRC protocol.
| Path/file | Description
| tests/ | Root of tests.
|    tests.cpp | Program used to run all tests.
|    scripts/ | Root of scripting API tests.
|       test-scripts.cpp | Program used to run the scripting API tests.
|       python/ | Python scripts to generate and run the scripting API tests.
|          testapigen.py | Python script generating scripts in all languages to test the scripting API.
|          testapi.py | Python script with scripting API tests, used by script testapigen.py.
|          unparse.py | Convert Python code to other languages, used by script testapigen.py.
|    unit/ | Root of unit tests.
|       test-plugins.cpp | Tests: plugins.
|       core/ | Root of unit tests for core.
|          test-core-arraylist.cpp | Tests: arraylists.
|          test-core-calc.cpp | Tests: calculation of expressions.
|          test-core-crypto.cpp | Tests: cryptographic functions.
|          test-core-eval.cpp | Tests: evaluation of expressions.
|          test-core-hashtble.cpp | Tests: hashtables.
|          test-core-hdata.cpp | Tests: hdata.
|          test-core-hook.cpp | Tests: hooks.
|          test-core-infolist.cpp | Tests: infolists.
|          test-core-list.cpp | Tests: lists.
|          test-core-secure.cpp | Tests: secured data.
|          test-core-string.cpp | Tests: strings.
|          test-core-url.cpp | Tests: URLs.
|          test-core-utf8.cpp | Tests: UTF-8.
|          test-core-util.cpp | Tests: utility functions.
|       gui/ | Root of unit tests for interfaces.
|          test-gui-color.cpp | Tests: colors.
|          test-gui-line.cpp | Tests: lines.
|          test-gui-nick.cpp | Tests: nicks.
|       plugins/ | Root of unit tests for plugins.
|          irc/ | Root of unit tests for IRC plugin.
|             test-irc-color.cpp | Tests: IRC colors.
|             test-irc-config.cpp | Tests: IRC configuration.
|             test-irc-ignore.cpp | Tests: IRC ignores.
|             test-irc-message.cpp | Tests: IRC messages.
|             test-irc-mode.cpp | Tests: IRC modes.
|             test-irc-nick.cpp | Tests: IRC nicks.
|             test-irc-protocol.cpp | Tests: IRC protocol.
|          relay/ | Root of unit tests for Relay plugin.
|             weechat/ | Root of unit tests for weechat protocol.
|                test-relay-weechat-protocol.cpp | Tests: weechat protocol.
|===
@@ -419,7 +428,7 @@ WeeChat "core" is located in following directories:
Documentation files:
[width="100%",cols="1m,3",options="header"]
[width="100%",cols="1m,2",options="header"]
|===
| Path/file | Description
| doc/ | Documentation.
@@ -445,7 +454,7 @@ Documentation files:
Translations for WeeChat and plugins are done with gettext, files are in _po/_
directory:
[width="100%",cols="1m,3",options="header"]
[width="100%",cols="1m,2",options="header"]
|===
| Path/file | Description
| po/ | Translation files (gettext).
@@ -475,7 +484,7 @@ Example in C:
/*
* weechat.c - core functions for WeeChat
*
* Copyright (C) 2019 Your Name <your@email.com>
* Copyright (C) 2020 Your Name <your@email.com>
*
* This file is part of WeeChat, the extensible chat client.
*
@@ -710,7 +719,7 @@ _irc.c_ in irc plugin.
Examples:
[width="100%",cols="1m,3",options="header"]
[width="100%",cols="1m,2",options="header"]
|===
| Directory | Files
| src/core/ | weechat.c, wee-backtrace.c, wee-command.c, ...
+96 -5
View File
@@ -374,19 +374,29 @@ Other solution is to use a script:
[[change_locale_without_quit]]
=== I want to change the language used by WeeChat for messages, but without exiting WeeChat, is it possible?
Yes, with WeeChat ≥ 1.0:
Sure it is possible:
----
/set env LANG en_US.UTF-8
/upgrade
----
With older WeeChat:
[[timezone]]
=== How can I change the timezone?
There is no option in WeeChat to change the timezone, the environment variable
`TZ` must be set to the appropriate value.
In your shell initialization file or on command line, before starting WeeChat:
----
/script install shell.py
/shell setenv LANG=en_US.UTF-8
/upgrade
export TZ=America/New_York
----
In WeeChat, the new value is immediately used:
----
/set env TZ America/New_York
----
[[use_256_colors]]
@@ -482,6 +492,87 @@ You can just disable bracketed paste mode:
/set weechat.look.paste_bracketed off
----
[[small_terminal]]
=== How can I customize display for very small terminal size (like 80x25), to not waste space?
You can remove side bars (buflist and nicklist), change time format to display
only hours and seconds, disable alignment of messages and set a char for nick
prefix/suffix:
----
/set buflist.look.enabled off
/bar hide nicklist
/set weechat.look.buffer_time_format "%H:%M"
/set weechat.look.prefix_align none
/set weechat.look.align_end_of_lines prefix
/set weechat.look.nick_suffix ">"
/set weechat.look.nick_prefix "<"
----
Terminal 80x25, with default configuration:
....
┌────────────────────────────────────────────────────────────────────────────────┐
│1.local │Welcome on WeeChat channel! │
│ weechat │16:27:16 --> | FlashCode (~flashcode@localhost) │@FlashCode│
│2. #weechat│ | has joined #weechat │ bob │
│ │16:27:16 -- | Mode #weechat [+nt] by hades.arpa │ │
│ │16:27:16 -- | Channel #weechat: 1 nick (1 op, 0 │ │
│ │ | voices, 0 normals) │ │
│ │16:27:18 -- | Channel created on Sun, 22 Mar │ │
│ │ | 2020 16:27:16 │ │
│ │17:02:28 --> | bob (~bob_user@localhost) has │ │
│ │ | joined #weechat │ │
│ │17:03:12 @FlashCode | hi bob, you're the first user │ │
│ │ | here, welcome on the WeeChat │ │
│ │ | support channel! │ │
│ │17:03:33 bob | hi FlashCode │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │ │ │
│ │[17:04] [2] [irc/local] 2:#weechat(+nt){2} │
│ │[@FlashCode(i)] █ │
└────────────────────────────────────────────────────────────────────────────────┘
....
Terminal 80x25, after changes:
....
┌────────────────────────────────────────────────────────────────────────────────┐
│Welcome on WeeChat channel! │
│16:27 --> FlashCode (~flashcode@localhost) has joined #weechat │
│16:27 -- Mode #weechat [+nt] by hades.arpa │
│16:27 -- Channel #weechat: 1 nick (1 op, 0 voices, 0 normals) │
│16:27 -- Channel created on Sun, 22 Mar 2020 16:27:16 │
│17:02 --> bob (~bob_user@localhost) has joined #weechat │
│17:03 <@FlashCode> hi bob, you're the first user here, welcome on the WeeChat │
│ support channel! │
│17:03 <bob> hi FlashCode │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│ │
│[17:04] [2] [irc/local] 2:#weechat(+nt){2} │
│[@FlashCode(i)] █ │
└────────────────────────────────────────────────────────────────────────────────┘
....
[[key_bindings]]
== Key bindings
File diff suppressed because it is too large Load Diff
+4 -1
View File
@@ -221,12 +221,15 @@ option name):
----
[[connect_to_irc_server]]
== Connect to IRC server and auto-join channels
== Connect to IRC server
----
/connect freenode
----
With this command, WeeChat connects to the freenode server and auto-joins the
channels configured in the "autojoin" server option.
[NOTE]
This command can be used to create and connect to a new server without using the
`/server` command (see `/help connect`).
+23
View File
@@ -116,6 +116,9 @@ Arguments:
* _option_: one of following options:
** _password_: password used to authenticate on _relay_
(option _relay.network.password_ in WeeChat)
** _password_hash_: hash of password used to authenticate on _relay_
(option _relay.network.password_ in WeeChat), see below for the format
_(WeeChat ≥ 2.8)_
** _totp_: Time-based One-Time Password (TOTP) used as secondary authentication
factor, in addition to the password
(option _relay.network.totp_secret_ in WeeChat)
@@ -129,6 +132,17 @@ Arguments:
With WeeChat ≥ 1.6, commas can be escaped in the value, for example
`init password=foo\,bar` to send the password "foo,bar".
Format of hashed password is one of the following, where _hash_ is the hashed
password as hexadecimal:
* `+sha256:hash+`
* `+sha512:hash+`
* `+pbkdf2:algorithm:salt:iterations:hash+` with:
** _algorithm_: _sha256_ or _sha512_
** _salt_: salt (hexadecimal)
** _iterations_: number of iterations
** _hash_: the hashed password (hexadecimal)
Examples:
----
@@ -143,6 +157,15 @@ init password=mypass,totp=123456
# initialize and disable compression
init password=mypass,compression=off
# initialize with hashed password (SHA256) (WeeChat ≥ 2.8)
init password_hash=sha256:b9a4c3393dfac4330736684510378851e581c68add8eca84110c31a33e694676
# initialize with hashed password (SHA512) (WeeChat ≥ 2.8)
init password_hash=sha512:4469190d4e0d1fdc0afb6f408d9873c89b8ce89cc4db79fe058255c55ad6821fa5e9bb068f9e578c8ae7cc825d85ff99c439d59e439bc589d95620a1e6b8ae6e
# initialize with hashed password (PBKDF2: SHA256, salt="ABCDEFGHIJKLMNOP", 100000 iterations) (WeeChat ≥ 2.8)
init password_hash=pbkdf2:sha256:4142434445464748494a4b4c4d4e4f50:100000:01757d53157ca14a1419e3a8cc1563536520a60b76d2d48e7f9ac09afc945a1c
----
[[command_hdata]]
+128 -29
View File
@@ -3,8 +3,9 @@
:email: flashcode@flashtux.org
:lang: en
:toc: left
:toclevels: 3
:toclevels: 4
:sectnums:
:sectnumlevels: 3
:docinfo1:
@@ -67,22 +68,89 @@ link:weechat_plugin_api.en.html#_hook_process[WeeChat plugin API reference].
==== Python
* You have to `import weechat`.
* Functions `+print*+` are called `+prnt*+` in python (because _print_ is reserved
keyword).
* Functions are called with `weechat.xxx(arg1, arg2, ...)`.
===== Module
WeeChat defines a `weechat` module which must be imported with `import weechat`.
===== Functions
Functions are called with `weechat.xxx(arg1, arg2, ...)`.
Functions `+print*+` are called `+prnt*+` in python (because `print` was a
reserved keyword in Python 2).
===== Strings received in callbacks
In Python 3 and with WeeChat ≥ 2.7, the strings received in callbacks have type
`str` if the string has valid UTF-8 data (which is the most common case),
or `bytes` if the string is not UTF-8 valid. So the callback should take care
about this type if some invalid UTF-8 content can be received.
Some invalid UTF-8 data may be received in these cases, so the callback can
receive a string of type `str` or `bytes` (this list is not exhaustive):
[width="100%",cols="3m,3m,3m,8",options="header"]
|===
| API function | Arguments | Examples | Description
| hook_modifier |
irc_in_yyy |
pass:[irc_in_privmsg] +
pass:[irc_in_notice] |
A message received in IRC plugin, before it is decoded to UTF-8 (used
internally). +
+
It is recommended to use modifier `irc_in2_yyy` instead, the string received
is always UTF-8 valid. +
See function `hook_modifier` in the
link:weechat_plugin_api.en.html#_hook_modifier[WeeChat plugin API reference].
| hook_signal |
xxx,irc_out_yyy +
xxx,irc_outtags_yyy |
pass:[*,irc_out_privmsg] +
pass:[*,irc_out_notice] +
pass:[*,irc_outtags_privmsg] +
pass:[*,irc_outtags_notice] |
A message sent by IRC plugin, after it is encoded to the `encode` charset
defined by the user (if different from the default `UTF-8`). +
+
It is recommended to use signal `xxx,irc_out1_yyy` instead, the string received
is always UTF-8 valid. +
See function `hook_signal` in the
link:weechat_plugin_api.en.html#_hook_signal[WeeChat plugin API reference].
| hook_process +
hook_process_hashtable |
- |
- |
Output of the command, sent to the callback, can contain invalid UTF-8 data.
|===
In Python 2, which is now deprecated and should not be used any more, the
strings sent to callbacks are always of type `str`, and may contain invalid
UTF-8 data, in the cases mentioned above.
==== Perl
* Functions are called with `weechat::xxx(arg1, arg2, ...);`.
===== Functions
Functions are called with `weechat::xxx(arg1, arg2, ...);`.
==== Ruby
* You have to define _weechat_init_ and call _register_ inside.
* Functions are called with `Weechat.xxx(arg1, arg2, ...)`.
* Due to a limitation of Ruby (15 arguments max by function), the function
`Weechat.config_new_option` receives the callbacks in an array of 6 strings
(3 callbacks + 3 data strings), so a call to this function looks like:
===== Initialization
You have to define _weechat_init_ and call _register_ inside.
===== Functions
Functions are called with `Weechat.xxx(arg1, arg2, ...)`.
Due to a limitation of Ruby (15 arguments max by function), the function
`Weechat.config_new_option` receives the callbacks in an array of 6 strings
(3 callbacks + 3 data strings), so a call to this function looks like:
[source,ruby]
----
@@ -92,29 +160,41 @@ Weechat.config_new_option(config, section, "name", "string", "description of opt
==== Lua
* Functions are called with `weechat.xxx(arg1, arg2, ...)`.
===== Functions
Functions are called with `weechat.xxx(arg1, arg2, ...)`.
==== Tcl
* Functions are called with `weechat::xxx arg1 arg2 ...`.
===== Functions
Functions are called with `weechat::xxx arg1 arg2 ...`.
==== Guile (Scheme)
* Functions are called with `(weechat:xxx arg1 arg2 ...)`.
* Following functions take one list of arguments (instead of many arguments
for other functions), because number of arguments exceed number of allowed
arguments in Guile:
** config_new_section
** config_new_option
** bar_new
===== Functions
Functions are called with `(weechat:xxx arg1 arg2 ...)`.
The following functions take one list of arguments (instead of many arguments
for other functions), because number of arguments exceed number of allowed
arguments in Guile:
* config_new_section
* config_new_option
* bar_new
==== JavaScript
* Functions are called with `weechat.xxx(arg1, arg2, ...);`.
===== Functions
Functions are called with `weechat.xxx(arg1, arg2, ...);`.
==== PHP
* Functions are called with `weechat_xxx(arg1, arg2, ...);`.
===== Functions
Functions are called with `weechat_xxx(arg1, arg2, ...);`.
[[register_function]]
=== Register function
@@ -1081,14 +1161,20 @@ weechat.prnt("", "value of option weechat.color.chat_delimiters is: %s"
[[irc_catch_messages]]
==== Catch messages
IRC plugin sends two signals for a message received (`xxx` is IRC internal
IRC plugin sends four signals for a message received (`xxx` is IRC internal
server name, `yyy` is IRC command name like JOIN, QUIT, PRIVMSG, 301, ..):
xxxx,irc_in_yyy::
signal sent before processing message
xxx,irc_in_yyy::
signal sent before processing message, only if message is *not* ignored
xxx,irc_in2_yyy::
signal sent after processing message
signal sent after processing message, only if message is *not* ignored
xxx,irc_raw_in_yyy::
signal sent before processing message, even if message is ignored
xxx,irc_raw_in2_yyy::
signal sent after processing message, even if message is ignored
[source,python]
----
@@ -1110,8 +1196,16 @@ weechat.hook_signal("*,irc_in2_join", "join_cb", "")
[[irc_modify_messages]]
==== Modify messages
IRC plugin sends a "modifier" called "irc_in_xxx" ("xxx" is IRC command) for a
message received, so that you can modify it.
IRC plugin sends two "modifiers" for a message received ("xxx" is IRC command),
so that you can modify it:
irc_in_xxx::
modifier sent before charset decoding: use with caution, the string may
contain invalid UTF-8 data; use only for raw operations on a message
irc_in2_xxx::
modifier sent after charset decoding, so the string received is always
UTF-8 valid (*recommended*)
[source,python]
----
@@ -1120,7 +1214,7 @@ def modifier_cb(data, modifier, modifier_data, string):
# (OK that's not very useful, but that's just an example!)
return "%s %s" % (string, modifier_data)
weechat.hook_modifier("irc_in_privmsg", "modifier_cb", "")
weechat.hook_modifier("irc_in2_privmsg", "modifier_cb", "")
----
[WARNING]
@@ -1153,6 +1247,10 @@ The result is a hashtable with following keys
The origin nick. |
`nick`
| user | ≥ 2.7 |
The origin user. |
`user`
| host | ≥ 0.3.4 |
The origin host (includes the nick). |
`nick!user@host`
@@ -1200,6 +1298,7 @@ dict = weechat.info_get_hashtable(
# "tags": "time=2015-06-27T16:40:35.000Z",
# "message_without_tags": ":nick!user@host PRIVMSG #weechat :hello!",
# "nick": "nick",
# "user": "user",
# "host": "nick!user@host",
# "command": "PRIVMSG",
# "channel": "#weechat",
+142 -42
View File
@@ -102,7 +102,7 @@ compile WeeChat.
| libncursesw5-dev ^(2)^ | | *yes* | Ncurses interface.
| libcurl4-gnutls-dev | | *yes* | URL transfer.
| zlib1g-dev | | *yes* | Compression of packets in relay plugin (weechat protocol), script plugin.
| libgcrypt20-dev | | *yes* | Secured data, IRC SASL authentication (DH-BLOWFISH/DH-AES), script plugin.
| libgcrypt20-dev | | *yes* | Secured data, IRC SASL authentication (DH-BLOWFISH/DH-AES).
| libgnutls28-dev | ≥ 2.2.0 ^(3)^ | | SSL connection to IRC server, support of SSL in relay plugin, IRC SASL authentication (ECDSA-NIST256P-CHALLENGE).
| gettext | | | Internationalization (translation of messages; base language is English).
| ca-certificates | | | Certificates for SSL connections.
@@ -110,7 +110,7 @@ compile WeeChat.
∥ libenchant-dev | | | Spell plugin.
| python3-dev | ^(4)^ | | Python plugin.
| libperl-dev | | | Perl plugin.
| ruby2.5, ruby2.5-dev | ≥ 1.8 | | Ruby plugin.
| ruby2.5, ruby2.5-dev | ≥ 1.9.1 | | Ruby plugin.
| liblua5.3-dev | | | Lua plugin.
| tcl-dev | ≥ 8.5 | | Tcl plugin.
| guile-2.0-dev | ≥ 2.0 | | Guile (scheme) plugin.
@@ -790,13 +790,22 @@ include::autogen/user/irc_colors.adoc[]
To show all available colors in your terminal, you can do `/color` then
kbd:[Alt+c] in WeeChat or run this command in terminal: `weechat --colors`.
Example: display of "hello everybody!" with "hello" in light blue bold and
"everybody" in light red underlined:
Example: display of "hello Alice!" with "hello" in light blue bold and
"Alice" in light red underlined:
----
^Cc12^Cbhello ^Cb^Cc04^C_everybody^C_^Cc!
^Cc12^Cbhello ^Cb^Cc04^C_Alice^C_^Cc!
----
Keys:
kbd:[Ctrl+c] kbd:[c] kbd:[1] kbd:[2] kbd:[Ctrl+c] kbd:[b] +
kbd:[h] kbd:[e] kbd:[l] kbd:[l] kbd:[o] kbd:[Space] +
kbd:[Ctrl+c] kbd:[b] kbd:[Ctrl+c] kbd:[c] kbd:[0] kbd:[4] kbd:[Ctrl+c] kbd:[pass:[_]] +
kbd:[A] kbd:[l] kbd:[i] kbd:[c] kbd:[e] +
kbd:[Ctrl+c] kbd:[pass:[_]] kbd:[Ctrl+c] kbd:[c] +
kbd:[!]
[NOTE]
In irc plugin, you can remap these colors using option
<<option_irc.color.mirc_remap,irc.color.mirc_remap>>.
@@ -1768,44 +1777,125 @@ These keys are used in context "mouse", namely when a mouse event occurs.
[width="100%",cols="^.^3,^.^3,^.^3,.^8,.^8",options="header"]
|===
| Button/Wheel ^(1)^ | Gesture | Area | Description | Command
| ◾◽◽ | - | chat | Switch to window. | `/window ${_window_number}`
| ◾◽◽ | left | chat | Switch to previous buffer. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | right | chat | Switch to next buffer. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | left (long) | chat | Switch to first buffer. | `/window ${_window_number};/buffer 1`
| ◾◽◽ | right (long) | chat | Switch to last buffer. | `/window ${_window_number};/input jump_last_buffer`
| ◾◽◽ | - | chat (script buffer) | Select line in script buffer. | `/script go ${_chat_line_y}`
| ◽◽◾ | - | chat (script buffer) | Install/remove script. | `/script go ${_chat_line_y};/script installremove -q ${script_name_with_extension}`
| kbd:[▲] | - | chat | Scroll up a few lines in buffer history. | `/window scroll_up -window ${_window_number}`
| kbd:[▼] | - | chat | Scroll down a few lines in buffer history. | `/window scroll_down -window ${_window_number}`
| kbd:[▲] | - | chat (script buffer) | Move 5 lines up in script buffer. | `/script up 5`
| kbd:[▼] | - | chat (script buffer) | Move 5 lines down in script buffer. | `/script down 5`
| kbd:[Ctrl+▲] | - | chat | Scroll horizontally to the left. | `/window scroll_horiz -window ${_window_number} -10%`
| kbd:[Ctrl+▼] | - | chat | Scroll horizontally to the right. | `/window scroll_horiz -window ${_window_number} +10%`
| ◽◽ | up / left | buflist | Move buffer to a lower number. | Signal `buflist_mouse`.
| ◽◽ | down / right | buflist | Move buffer to a higher number. | Signal `buflist_mouse`.
| ◽◽ | - | buflist | Switch to buffer (previously visited buffer if the buffer is the current one). | Signal `buflist_mouse`.
| ◽◽◾ | - | buflist | Switch to next visited buffer if the buffer is the current one. | Signal `buflist_mouse`.
| kbd:[Ctrl+▲] | - | buflist | Switch to previous buffer. | Signal `buflist_mouse`.
| kbd:[Ctrl+▼] | - | buflist | Switch to next buffer. | Signal `buflist_mouse`.
| ◽◽ | up | nicklist | Scroll up one page in nicklist. | `/bar scroll nicklist ${_window_number} -100%`
| ◾◽◽ | down | nicklist | Scroll down one page in nicklist. | `/bar scroll nicklist ${_window_number} +100%`
| ◾◽◽ | up (long) | nicklist | Go to the beginning of nicklist. | `/bar scroll nicklist ${_window_number} b`
| ◾◽◽ | down (long) | nicklist | Go to the end of nicklist. | `/bar scroll nicklist ${_window_number} e`
| ◽◽ | - | nicklist | Open query with nick. | `/window ${_window_number};/query ${nick}`
| ◽◽◾ | - | nicklist | Do a whois on nick. | `/window ${_window_number};/whois ${nick}`
| ◾◽◽ | left | nicklist | Kick nick. | `/window ${_window_number};/kick ${nick}`
| ◾◽◽ | left (long) | nicklist | Kick and ban nick. | `/window ${_window_number};/kickban ${nick}`
| ◽◽ | left | nicklist | Ban nick. | `/window ${_window_number};/ban ${nick}`
| ◽◽ | - | input | Grab a mouse event and insert its code in command line. | `/input grab_mouse_area`
| kbd:[▲] | - | any bar | Scroll bar by -20%. | `/bar scroll ${_bar_name} ${_window_number} -20%`
| kbd:[▼] | - | any bar | Scroll bar by +20%. | `/bar scroll ${_bar_name} ${_window_number} +20%`
| ◽◽ | - | anywhere | Start cursor mode at this point. | `/cursor go ${_x},${_y}`
| Button/Wheel ^(1)^ | Gesture | Area | Description | Command
| ◾◽◽ | - | chat | Switch to window. | `/window ${_window_number}`
| ◾◽◽ | left | chat | Switch to previous buffer. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | right | chat | Switch to next buffer. | `/window ${_window_number};/buffer +1`
| ◾◽◽ | left (long) | chat | Switch to first buffer. | `/window ${_window_number};/buffer 1`
| ◾◽◽ | right (long) | chat | Switch to last buffer. | `/window ${_window_number};/input jump_last_buffer`
| kbd:[▲] | - | chat | Scroll up a few lines in buffer history. | `/window scroll_up -window ${_window_number}`
| kbd:[▼] | - | chat | Scroll down a few lines in buffer history. | `/window scroll_down -window ${_window_number}`
| kbd:[Ctrl+▲] | - | chat | Scroll horizontally to the left. | `/window scroll_horiz -window ${_window_number} -10%`
| kbd:[Ctrl+▼] | - | chat | Scroll horizontally to the right. | `/window scroll_horiz -window ${_window_number} +10%`
| kbd:[▲] | - | chat: fset buffer | Move five lines up in fset buffer. | `/fset -up 5`
| kbd:[▼] | - | chat: fset buffer | Move five lines down in fset buffer. | `/fset -down 5`
| ◾◽◽ | - | chat: fset buffer | Select line in fset buffer. | `/window ${_window_number};/fset -go ${_chat_line_y}`
| ◽◽◾ | - | chat: fset buffer | Toggle boolean (on/off) or edit the option value. | `hsignal:fset_mouse`
| ◽◽ | left | chat: fset buffer | Decrease value for integer/color, set/append to value for other types. | `hsignal:fset_mouse`
| ◽◽ | right | chat: fset buffer | Increase value for integer/color, set/append to value for other types. | `hsignal:fset_mouse`
| ◽◽ | up / down | chat: fset buffer | Mark/unmark multiple options. | `hsignal:fset_mouse`
| kbd:[▲] | - | chat: script buffer | Move five lines up in script buffer. | `/script up 5`
| kbd:[▼] | - | chat: script buffer | Move five lines down in script buffer. | `/script down 5`
| ◾◽◽ | - | chat: script buffer | Select line in script buffer. | `/script go ${_chat_line_y}`
| ◽◽ | - | chat: script buffer | Install/remove script. | `/script go ${_chat_line_y};/script installremove -q ${script_name_with_extension}`
| ◾◽◽ | up / left | buflist | Move buffer to a lower number. | Signal `buflist_mouse`.
| ◾◽◽ | down / right | buflist | Move buffer to a higher number. | Signal `buflist_mouse`.
| ◾◽◽ | - | buflist | Switch to buffer (previously visited buffer if the buffer is the current one). | Signal `buflist_mouse`.
| ◽◽ | - | buflist | Switch to next visited buffer if the buffer is the current one. | Signal `buflist_mouse`.
| kbd:[Ctrl+▲] | - | buflist | Switch to previous buffer. | Signal `buflist_mouse`.
| kbd:[Ctrl+▼] | - | buflist | Switch to next buffer. | Signal `buflist_mouse`.
| ◾◽◽ | up | nicklist | Scroll up one page in nicklist. | `/bar scroll nicklist ${_window_number} -100%`
| ◽◽ | down | nicklist | Scroll down one page in nicklist. | `/bar scroll nicklist ${_window_number} +100%`
| ◽◽ | up (long) | nicklist | Go to the beginning of nicklist. | `/bar scroll nicklist ${_window_number} b`
| ◾◽◽ | down (long) | nicklist | Go to the end of nicklist. | `/bar scroll nicklist ${_window_number} e`
| ◾◽◽ | - | nicklist | Open query with nick. | `/window ${_window_number};/query ${nick}`
| ◽◽ | - | nicklist | Do a whois on nick. | `/window ${_window_number};/whois ${nick}`
| ◾◽◽ | left | nicklist | Kick nick. | `/window ${_window_number};/kick ${nick}`
| ◾◽◽ | left (long) | nicklist | Kick and ban nick. | `/window ${_window_number};/kickban ${nick}`
| ◽◽◾ | left | nicklist | Ban nick. | `/window ${_window_number};/ban ${nick}`
| ◽◽◾ | - | input | Grab a mouse event and insert its code in command line. | `/input grab_mouse_area`
| kbd:[▲] | - | any bar | Scroll bar by -20%. | `/bar scroll ${_bar_name} ${_window_number} -20%`
| kbd:[▼] | - | any bar | Scroll bar by +20%. | `/bar scroll ${_bar_name} ${_window_number} +20%`
| ◽◾◽ | - | anywhere | Start cursor mode at this point. | `/cursor go ${_x},${_y}`
|===
[NOTE]
^(1)^ kbd:[▲] and kbd:[▼] are wheel up and down.
[[key_bindings_fset_buffer]]
==== Keys for fset buffer
These keys and actions are used on the fset buffer (see <<fset_plugin,Fset plugin>>).
[width="100%",cols="^.^3,^.^2,.^8,.^5",options="header"]
|===
| Key | Action ^(1)^ | Description | Command
| kbd:[↑] | | Move one line up. | `/fset -up`
| kbd:[↓] | | Move one line down. | `/fset -down`
| kbd:[PgUp] | | Move one page up. | `/window page_up`
| kbd:[PgDn] | | Move one page down. | `/window page_down`
| kbd:[Alt+Home] | `pass:[<<]` | Move to first line. | `/fset -go 0`
| kbd:[Alt+End] | `pass:[>>]` | Move to last line. | `/fset -go end`
| kbd:[F11] | `pass:[<]` | Scroll horizontally on the left. | `/fset -left`
| kbd:[F12] | `pass:[>]` | Scroll horizontally on the right. | `/fset -right`
| kbd:[Alt+Space] | `t` | Toggle boolean value. | `/fset -toggle`
| kbd:[Alt+-] | `-` | Subtract 1 from value for integer/color, set value for other types. | `/fset -add -1`
| kbd:[Alt++] | `+` | Add 1 to value for integer/color, append to value for other types. | `/fset -add 1`
| kbd:[Alt+f],
kbd:[Alt+r] | `r` | Reset value. | `/fset -reset`
| kbd:[Alt+f],
kbd:[Alt+u] | `u` | Unset value. | `/fset -unset`
| kbd:[Alt+Enter] | `s` | Set value. | `/fset -set`
| kbd:[Alt+f],
kbd:[Alt+n] | `n` | Set new value. | `/fset -setnew`
| kbd:[Alt+f],
kbd:[Alt+a] | `a` | Append to value. | `/fset -append`
| kbd:[Alt+,] | `,` | Mark/unmark option. | `/fset -mark 1`
| kbd:[Shift+↑] | | Move one line up and mark/unmark option. | `/fset -up; /fset -mark`
| kbd:[Shift+↓] | | Mark/unmark option and move one line down. | `/fset -mark; /fset -down`
| | `m:xxx` | Mark options displayed that are matching filter "xxx" (any filter on option or value is allowed, see <<command_fset_fset,fset command>>). |
| | `u:xxx` | Unmark options displayed that are matching filter "xxx" (any filter on option or value is allowed, see <<command_fset_fset,fset command>>). |
| kbd:[Ctrl+l] (`L`) | | Refresh options and whole screen. | `/fset -refresh`
| | `$` | Refresh options (keep marked options). |
| | `$$` | Refresh options (unmark all options). |
| kbd:[Alt+p] | | Toggle plugin description options (`pass:[plugins.desc.*]`). | `/mute /set fset.look.show_plugins_desc toggle`
| kbd:[Alt+v] | | Toggle help bar. | `/bar toggle fset`
| | `s:x,y` | Sort options by fields x,y (see option <<option_fset.look.sort,fset.look.sort>>). | `/mute /set fset.look.sort x,y`
| | `s:` | Reset sort to its default value (see option <<option_fset.look.sort,fset.look.sort>>). | `/mute /unset fset.look.sort`
| | `w:xxx` | Export options in file "xxx". | `/fset -export xxx`
| | `w-:xxx` | Export options in file "xxx" without help. | `/fset -export -nohelp xxx`
| | `w+:xxx` | Export options in file "xxx" with help. | `/fset -export -help xxx`
| kbd:[Ctrl+x] | `x` | Switch the format used to display options. | `/fset -format`
| | `q` | Close fset buffer. | `/buffer close`
|===
[NOTE]
^(1)^ The action must be entered as input on the command line, followed by kbd:[Enter].
[[key_bindings_script_buffer]]
==== Keys for script buffer
These keys and actions are used on the script buffer (see <<scripts_plugins,Script plugin>>).
[width="100%",cols="^.^3,^.^2,.^8,.^5",options="header"]
|===
| Key | Action ^(1)^ | Description | Command
| kbd:[↑] | | Move one line up. | `/script up`
| kbd:[↓] | | Move one line down. | `/script down`
| kbd:[PgUp] | | Move one page up. | `/window page_up`
| kbd:[PgDn] | | Move one page down. | `/window page_down`
| kbd:[Alt+i] | `i` | Install script. | `/script install`
| kbd:[Alt+r] | `r` | Remove script. | `/script remove`
| kbd:[Alt+l] (`L`) | `l` | Load script. | `/script load`
| kbd:[Alt+u] | `u` | Unload script. | `/script unload`
| kbd:[Alt+Shift+A] | `A` | Autoload script. | `/script toggleautoload`
| kbd:[Alt+h] | `h` | Hold/unhold script. | `/script hold`
| kbd:[Alt+v] | `v` | View script. | `/script show`
|===
[NOTE]
^(1)^ The action must be entered as input on the command line, followed by kbd:[Enter].
[[mouse]]
=== Mouse support
@@ -2084,8 +2174,15 @@ a _script_ is a text file loaded with a plugin like _python_ with command
You can use command `/plugin` to load/unload a plugin, or list all loaded
plugins.
When a plugin is unloaded, all buffers created by this plugin are
automatically closed.
When a plugin is unloaded, WeeChat removes:
* buffers
* configuration options (options are written in files)
* all hooks: commands, modifiers, process, etc.
* infos and infolists
* hdata
* bar items.
Examples to load, unload or list plugins:
@@ -2958,12 +3055,15 @@ Some examples:
==== Filenames masks
It is possible to define a filename mask for each buffer, and use local buffer
variables to build filename. To see local variables for current buffer:
variables to build filename. To see available local variables for current buffer:
----
/buffer localvar
----
Masks will be matched on options in descending order of specificity on
`logger.mask.$plugin.*`, with `logger.file.mask` as fallback option.
For example, on buffer "irc.freenode.#weechat", WeeChat will search a mask with
option name, in this order:
@@ -4013,7 +4113,7 @@ The "line" callback sets following variables in hashtable:
| str_time | string | Date for display. It may contain color codes.
| tags | string | Tags of message (with comma added at beginning/end of string).
| displayed | string | "1" if displayed, "0" if line filtered.
| notify_level | string | "0" = low level, "1" = message, "2" = private message, "3" = highlight
| notify_level | string | "-1" = no notify, "0" = low level, "1" = message, "2" = private message, "3" = highlight
| highlight | string | "1" if highlight, otherwise "0".
| prefix | string | Prefix.
| tg_prefix_nocolor | string | Prefix without color codes.
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2012-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2012-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2012-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2012-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+4
View File
@@ -262,6 +262,10 @@ donde "xxx" es el nombre de la opción.
/connect freenode
----
// TRANSLATION MISSING
With this command, WeeChat connects to the freenode server and auto-joins the
channels configured in the "autojoin" server option.
// TRANSLATION MISSING
[NOTE]
Este comando también puede usarse para crear y conectarse a un nuevo
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
#
# This file is part of WeeChat, the extensible chat client.
#
+1 -1
View File
@@ -1,5 +1,5 @@
#
# Copyright (C) 2003-2019 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2003-2020 Sébastien Helleu <flashcode@flashtux.org>
# Copyright (C) 2006 Julien Louis <ptitlouis@sysif.net>
#
# This file is part of WeeChat, the extensible chat client.
+3 -1
View File
@@ -38,6 +38,8 @@
| irc | irc_privates | privés sur tous les serveurs IRC
| irc | irc_raw_filters | filtres pour le tampon de données brutes irc
| irc | irc_server | serveur IRC courant
| irc | irc_server_channels | canaux sur le serveur IRC courant
@@ -142,7 +144,7 @@
| weechat | env_vars | variables d'environnement
| weechat | filename | nom de fichier
| weechat | filename | nom de fichier ; paramètre optionnel : chemin par défaut (évalué, voir /help eval)
| weechat | filters_names | noms des filtres
+2
View File
@@ -213,6 +213,7 @@ _last_irc_server_ +
| _name_   (string) +
_options_   (pointer) +
_temp_server_   (integer) +
_fake_server_   (integer) +
_reloading_from_config_   (integer) +
_reloaded_from_config_   (integer) +
_addresses_eval_   (string) +
@@ -546,6 +547,7 @@ _layout_number_   (integer) +
_layout_number_merge_order_   (integer) +
_name_   (string) +
_full_name_   (string) +
_old_full_name_   (string) +
_short_name_   (string) +
_type_   (integer) +
_notify_   (integer) +
+6 -2
View File
@@ -80,6 +80,8 @@
| tcl | tcl_version | version de l'interpréteur utilisé | -
| weechat | auto_connect | 1 si la connexion automatique aux serveurs est activée, 0 si elle a été désactivée par l'utilisateur (option "-a" ou "--no-connect") | -
| weechat | charset_internal | charset interne à WeeChat | -
| weechat | charset_terminal | charset du terminal | -
@@ -116,11 +118,11 @@
| weechat | term_width | largeur du terminal | -
| weechat | totp_generate | générer un mot de passe à usage unique basé sur le temps (TOTP) | secret (en base32), horodatage (optionnel, heure courante par défaut), nombre de chiffres (optionnal, entre 4 et 10, 6 par défaut)
| weechat | totp_generate | générer un mot de passe à usage unique basé sur le temps (TOTP) | secret (en base32), horodatage (optionnel, heure courante par défaut), nombre de chiffres (optionnel, entre 4 et 10, 6 par défaut)
| weechat | totp_validate | valider un mot de passe à usage unique basé sur le temps (TOTP) : 1 si le TOTP est correct, sinon 0 | secret (en base32), mot de passe à usage unique, horodatage (optionnel, heure courante par défaut), nombre de mots de passe avant/après à tester (optionnel, 0 par défaut)
| weechat | uptime | Uptime de WeeChat (format : "jours:hh:mm:ss") | "days" (nombre de jours) ou "seconds" (nombre de secondes) (optionnel)
| weechat | uptime | Durée de fonctionnement de WeeChat (format : "jours:hh:mm:ss") | "days" (nombre de jours) ou "seconds" (nombre de secondes) (optionnel)
| weechat | version | version de WeeChat | -
@@ -130,6 +132,8 @@
| weechat | weechat_dir | répertoire de WeeChat | -
| weechat | weechat_headless | 1 si WeeChat tourne sans interface | -
| weechat | weechat_libdir | répertoire "lib" de WeeChat | -
| weechat | weechat_localedir | répertoire "locale" de WeeChat | -
@@ -6,7 +6,7 @@
|===
| Extension | Nom | Description | Table de hachage (entrée) | Table de hachage (sortie)
| irc | irc_message_parse | analyse un message IRC | "message" : message IRC, "server" : nom du serveur (optionnel) | "tags" : étiquettes, "message_without_tags" : message sans les étiquettes, "nick" : pseudo, "host" : nom d'hôte, "command" : commande, "channel" : canal, "arguments" : paramètres (inclut le canal), "text" : texte (par exemple message utilisateur), "pos_command" : index de "command" dans le message ("-1" si "command" n'a pas été trouvé), "pos_arguments" : index de "arguments" dans le message ("-1" si "arguments" n'a pas été trouvé), "pos_channel" : index de "channel" dans le message ("-1" si "channel" n'a pas été trouvé), "pos_text" : index de "text" dans le message ("-1" si "text" n'a pas été trouvé)
| irc | irc_message_parse | analyse un message IRC | "message" : message IRC, "server" : nom du serveur (optionnel) | "tags" : étiquettes, "message_without_tags" : message sans les étiquettes, "nick" : pseudo, "user" : nom d'utilisateur, "host" : nom d'hôte, "command" : commande, "channel" : canal, "arguments" : paramètres (inclut le canal), "text" : texte (par exemple message utilisateur), "pos_command" : index de "command" dans le message ("-1" si "command" n'a pas été trouvé), "pos_arguments" : index de "arguments" dans le message ("-1" si "arguments" n'a pas été trouvé), "pos_channel" : index de "channel" dans le message ("-1" si "channel" n'a pas été trouvé), "pos_text" : index de "text" dans le message ("-1" si "text" n'a pas été trouvé)
| irc | irc_message_split | découper un message IRC (pour tenir dans les 512 octets par défaut) | "message" : message IRC, "server" : nom du serveur (optionnel) | "msg1" ... "msgN" : messages à envoyer (sans le "\r\n" final), "args1" ... "argsN" : paramètres des messages, "count" : nombre de messages
@@ -20,6 +20,9 @@ Les lignes avec les tampons sont affichées en utilisant l'évaluation de chaîn
Les variables suivantes peuvent être utilisées dans ces options :
- données de l'objet de barre (voir le hdata "bar_item" dans la doc API pour une liste complète), par exemple :
- ${bar_item.name}
- données de la fenêtre ("window"), où l'objet de barre est affiché (il n'y a pas de fenêtre pour les barres de type "root", voir le hdata "window" dans la doc API pour une liste complète), par exemple :
- ${window.number}
- ${window.buffer.full_name}
- données du tampon (voir le hdata "buffer" dans la doc API pour une liste complète), par exemple :
- ${buffer.number}
- ${buffer.name}
+1 -1
View File
@@ -70,7 +70,7 @@ Exemples :
/exec -n -norc url:https://pastebin.com/raw.php?i=xxxxxxxx
/exec -nf -noln links -dump https://weechat.org/files/doc/devel/weechat_user.en.html
/exec -o uptime
/exec -pipe "/print Uptime de la machine :" uptime
/exec -pipe "/print Durée de fonctionnement de la machine :" uptime
/exec -n tail -f /var/log/messages
/exec -kill 0
----

Some files were not shown because too many files have changed in this diff Show More