43 Commits

Author SHA1 Message Date
Sébastien Helleu
ad5fa7c99f core: add command /toggle 2021-10-01 22:55:38 +02:00
Sébastien Helleu
89e43eaf40 core: set server name when connecting to server with TLS (SNI extension) only if it's not an IPV4/IPv6 (closes #1635) 2021-05-16 14:52:11 +02:00
Sébastien Helleu
269576eea2 core: move directory/file functions from wee-util.c to wee-dir.c (issue #1285) 2021-05-11 21:06:29 +02:00
Sébastien Helleu
0dc7fbcb0c core: add options to customize commands on system signals, quit by default on SIGHUP when not running headless (closes #1595)
New options to customize behavior on signals received, with the default
behavior:

- weechat.signal.sighup: quit in normal mode, reload config in headless
- weechat.signal.sigquit: quit
- weechat.signal.sigterm: quit
- weechat.signal.sigusr1: no command executed by default
- weechat.signal.sigusr2: no command executed by default

The signals SIGUSR1 and SIGUSR2 are introduced by this commit, so it's now
possible to run commands when they are received.

The SIGHUP signal makes now WeeChat quit, it was the behavior before version
2.9 of WeeChat (see commit de1e61f7cd50cbd1a99777fe6611642a51abf5f6).
2021-03-16 18:47:31 +01:00
Sébastien Helleu
efc7a588d6 core: update copyright dates 2021-01-02 21:34:16 +01:00
Sébastien Helleu
62ccee9505 tests: run tests on plugins only if the plugins are enabled and compiled 2020-05-17 15:29:06 +02: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
feb6258910 core: update copyright dates 2020-01-04 10:41:26 +01:00
Sébastien Helleu
a8ca4b5b3a tests: add tests on GUI color functions 2019-10-01 18:31:41 +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
80f103b68a core: use fixed-width integer for computing nick hash (issue #1394) 2019-08-19 23:27:11 +02:00
Sébastien Helleu
2f37de9148 core: make "input_commands_allowed" work with /wait and /repeat commands (issue #928) 2019-03-28 18:45:22 +01:00
Sébastien Helleu
34bf68d38e tests: remove extra output before/after tests 2019-03-23 20:08:17 +01:00
Sébastien Helleu
c96e2f3593 tests: add tests on function irc_config_check_autojoin 2019-01-11 22:27:28 +01:00
Sébastien Helleu
2b0057239b core: update copyright dates 2019-01-01 15:40:51 +01:00
Sébastien Helleu
4712d0bb06 core: use https for links to GNU GPL license 2018-11-29 23:16:07 +01:00
Sébastien Helleu
d0ea801724 core: add support of TOTP generation/validation (Time-based One-Time Password) 2018-11-02 14:06:14 +01:00
Sébastien Helleu
466dbbe75b core: add option "-P" (or "--plugins") to customize the plugins to load at startup
If given, the option replaces the option weechat.plugin.autoload.
2018-08-17 19:44:41 +02:00
Sébastien Helleu
ca90f28beb tests: add tests on modifier hook 2018-08-16 18:27:04 +02:00
Sébastien Helleu
12a6f74ec0 core: fix check of tags in lines
All changes:
- fix check of tags in lines: check lines without tags, fix check of tags with
  negation ("!tag")
- add string functions string_split_tags and string_free_split_tags
- add tests on function gui_line_match_tags
2018-08-12 20:30:13 +02:00
Sébastien Helleu
805717e9ec core: add binary weechat-headless to run WeeChat without interface (closes #1120)
The optional command line option "--daemon" runs WeeChat like a daemon
(fork, new process group, file descriptors closed).
2018-03-11 09:59:39 +01:00
Sébastien Helleu
ed4837b2f6 core: update copyright dates 2018-01-05 00:54:18 +01:00
Sébastien Helleu
e8af853624 tests: add scripting API tests (issue #104)
Automatic tests of scripting API are made with Python scripts:

- unparse.py: convert Python code to other languages
- testapigen.py: generate scripts in all languages to test the API
- testapi.py scripting API tests
2017-10-07 16:51:25 +02:00
Sébastien Helleu
137d5863e2 tests: run command "/debug libs" in tests instead of Travis CI command 2017-10-01 08:00:39 +02:00
Sébastien Helleu
16661b0cbe tests: display an error if the required locale en_US.UTF-8 is not installed 2017-07-23 15:12:40 +02:00
Sébastien Helleu
8efbf61e66 tests: fix load of plugins in tests after a build with autotools 2017-07-05 21:33:19 +02:00
Linus Heckemann
d6c1d02eca core: search WEECHAT_EXTRA_LIBDIR for plugins (closes #971, issue #979)
In addition to searching the statically configured WEECHAT_LIBDIR
(weechat's installation directory) for plugins, search the path
given in the environment variable WEECHAT_EXTRA_LIBDIR. This makes
departing from the FHS standard while keeping the plugins packaged
separately easier. This change was made specifically with the Nix
package manager in mind, but can easily be used by others.
2017-07-05 19:52:48 +02:00
Sébastien Helleu
5e48b50da8 tests: fix double load of plugins when "make install" is executed before tests 2017-07-05 19:41:11 +02:00
Sébastien Helleu
a59ce8331a tests: load plugins from build directory instead of installed libdir
This allows to run tests without running "make install".
2017-07-04 22:14:44 +02:00
Sébastien Helleu
f99c866f35 core: add cut of string with max chars displayed in evaluation of expressions
The syntax is: ${cutscr:max,suffix,string}.
The string is cut after max chars displayed on screen. If the string is cut,
the optional suffix is added after.
2017-03-27 21:14:51 +02:00
Sébastien Helleu
705d86e684 core: update copyright dates 2017-01-01 11:32:04 +01:00
Sébastien Helleu
cf6aca1619 core: add pointer in some callbacks (closes #406)
This pointer is the first argument received by callbacks, and the
existing argument "data" is now automatically freed by WeeChat when the
object containing the callback is removed.

With this new pointer, the linked list of callbacks in scripts has been
removed. This will improve speed of scripts (using a lot of hooks),
reduce memory used by scripts and reduce time to unload scripts.

Following functions are affected in the C API:

* exec_on_files
* config_new
* config_new_section
* config_new_option
* hook_command
* hook_command_run
* hook_timer
* hook_fd
* hook_process
* hook_process_hashtable
* hook_connect
* hook_print
* hook_signal
* hook_hsignal
* hook_config
* hook_completion
* hook_modifier
* hook_info
* hook_info_hashtable
* hook_infolist
* hook_hdata
* hook_focus
* unhook_all_plugin
* buffer_new
* bar_item_new
* upgrade_new
* upgrade_read
2016-03-21 18:11:21 +01:00
Sébastien Helleu
3330724574 core: update copyright dates 2016-01-01 11:09:53 +01:00
Sébastien Helleu
415dea5c74 tests: fix locale used to execute tests 2015-12-24 22:48:10 +01:00
Sébastien Helleu
6ff8de5740 tests: check if all plugins are loaded 2015-12-24 22:21:33 +01:00
Sébastien Helleu
a020c28ea6 core: update copyright dates 2015-01-01 09:23:23 +01:00
Sébastien Helleu
dda1a66fd7 tests: add tests of arraylist functions 2014-09-01 11:51:04 +02:00
Sébastien Helleu
f39b37351c tests: fix build of tests when the build directory is outside source tree (closes #178) 2014-08-25 07:38:38 +02:00
Sébastien Helleu
bc34c3cfc2 tests: fix memory leak in tests launcher 2014-08-15 15:08:31 +02:00
Sébastien Helleu
dcf46a2ca0 tests: read WeeChat command line arguments in environment variable "WEECHAT_TESTS_ARGS" 2014-08-14 19:15:25 +02:00
Sébastien Helleu
f9b04635d3 tests: fix compilation of tests
The header gui-curses.h doesn't need to be included (this causes an error
because the real ncurses lib header is not found when compiling tests).
2014-08-02 11:38:58 +02:00
Sébastien Helleu
29385e39be tests: fix compilation warning with autotools 2014-07-21 21:25:55 +02:00
Sébastien Helleu
db9a8e7bc4 tests: add unit tests using CppUTest
The tests can be run only via CMake:

  1. build with tests: cmake .. -DENABLE_TESTS=ON
  2. make
  3. ctest  (or ctest -V for verbose output)
2014-07-20 12:13:25 +02:00