Commit graph

87 commits

Author SHA1 Message Date
jesopo
5dc5e3fbfd LIGHTGREEN -> GREEN for successful commands (commands.py) 2019-01-17 21:10:12 +00:00
jesopo
eadb49d41a Don't use bolding for command colors (commands.py) 2019-01-11 20:57:52 +00:00
jesopo
3d60d59510 We need to normalise between a single usage string and multiple (making both
lists) to reuse the formatting code (commands.py)
2018-12-29 21:38:03 +00:00
jesopo
ee8d3a6287 Remove an erroneous level of indentation that prevented the command being
prepended to a usage string when only 1 usage string was available (commands.py)
2018-12-29 21:35:06 +00:00
jesopo
bd8ca2083b Typo, 'aliase' -> 'aliases' (commands.py) 2018-12-22 01:06:42 +00:00
jesopo
be1d06796b Add !removealias (commands.py) 2018-12-22 01:05:47 +00:00
jesopo
3039119f4a Actually set new args_split (commands.py) 2018-12-22 01:02:55 +00:00
jesopo
ae5eb9fc47 .partition returns a tuple of 3 (commands.py) 2018-12-22 01:01:25 +00:00
jesopo
498c1d647e Add basics of a command alias system 2018-12-22 01:00:38 +00:00
jesopo
44d2455766 This regex should have been r"" (commands.py) 2018-12-22 00:49:00 +00:00
jesopo
8b9062b942 Better constifying of color/font chars 2018-11-13 16:02:26 +00:00
jesopo
fad4715b5c Add "prefixed-commands" to !channelset 2018-11-12 23:00:51 +00:00
jesopo
0c8678d44f Add a way to tell bitbot to only response to highlight-based commands (e.g. "bitbot: ping") but ignore prefixed commands (e.g. "!ping") 2018-11-12 22:59:21 +00:00
jesopo
49a21b2d36 Add a way to prevent responses to commands at all in specific channels 2018-11-12 22:55:40 +00:00
jesopo
1696492a78 Add ability to hide [Prefix] from command outputs 2018-11-07 11:27:10 +00:00
jesopo
24e4e2c5ad Add a way to silently stop commands executing in modules/commands.py
(preprocess.command)
2018-11-02 11:13:43 +00:00
jesopo
4fcb80b834 serverset identity-mechanism should be in modules/permissions.py 2018-11-02 11:08:03 +00:00
jesopo
b34f4d70a5 Remove extra ) in modules/commands.py 2018-10-28 11:54:55 +00:00
jesopo
5553ac9e49 Typo in modules/command.py, 'is' -> 'if' 2018-10-28 11:53:31 +00:00
jesopo
ec72787f86 Support multiple "usage" values in commands.py 2018-10-28 11:50:56 +00:00
jesopo
547c57c8b8 str(utils.EventError) should be written to stderr, not stdout 2018-10-16 15:15:20 +01:00
jesopo
42a1cda92c 'EventManager.EventError' -> 'utils.EventError' in modules/commands.py 2018-10-16 14:49:01 +01:00
jesopo
ba3cd00c78 Add utils.EventError, utilise it for stderr in commands.py/coins.py 2018-10-16 14:47:01 +01:00
jesopo
376825ea96 Mark command hooks that are aliases ('g' vs 'google') 2018-10-10 10:42:41 +01:00
jesopo
b778ad2902 Support denoting command response [prefix] in docstring 2018-10-04 11:04:24 +01:00
jesopo
09b6f52d8e Fix showing usage when a user doesn't provide enough args to a command 2018-10-03 17:01:26 +01:00
jesopo
02e76444d1 Add 'remove_empty' kwarg for commands, to strip out empty space 2018-10-03 17:01:10 +01:00
jesopo
69d58eede2 Move src/Utils.py in to src/utils/, splitting functionality out in to modules of
related functionality
2018-10-03 13:22:37 +01:00
jesopo
9118af5e9c Support changing command responses from PRIVMSG to NOTICE 2018-10-02 21:40:34 +01:00
jesopo
22740e2faa Re-add lost "!" prefix on stderr prefix 2018-10-02 17:48:07 +01:00
jesopo
a7563c9653 Pass msgid in send_stdout/send_stdin in modules/commands.py 2018-10-02 14:22:42 +01:00
jesopo
a76f206551 It's 'draft/msgid' not just 'msgid', also actually store 'msgid' in self._msgid 2018-10-01 17:52:04 +01:00
jesopo
26bfd61487 The correct msgid reply tag (at the moment) is '+draft/reply' 2018-10-01 17:28:45 +01:00
jesopo
976b6ae335 Better support for msgtags with PRIVMSGs; put functionality in to
modules/commands.py to reply to specific messages by use of msgids
2018-10-01 17:26:31 +01:00
jesopo
e9416034df Typo in modules.commands.py, 'unsafe_call' -> 'call_unsafe' 2018-10-01 16:32:24 +01:00
jesopo
7eb31820d7 Add call_unsafe functions to EventManager.EventHook, to not swallow errors on
specific function calls (e.g. preprocess.command)
2018-10-01 16:04:06 +01:00
jesopo
1cbca6fb88 Update a reference from buffer to target.buffer in modules/commands.py 2018-09-30 20:53:58 +01:00
jesopo
10ef985a8a Switch to using docstring for usage, permission and require_mode 2018-09-30 17:29:09 +01:00
jesopo
30641ce312 We don't need to explicitly pass "buffer" through on command events 2018-09-30 11:43:34 +01:00
jesopo
3dbd997a90 Better .strip()/.split() logic for !help 2018-09-29 10:50:25 +01:00
jesopo
746155fd57 Support command hooks not coming from a class instance 2018-09-29 09:44:13 +01:00
jesopo
6eb8b1ba6d Move all exports to @Utils.export calls 2018-09-27 12:08:07 +01:00
jesopo
51a52e2b0e Switch to using @Utils.hook and docstrings for event hooks 2018-09-26 18:27:17 +01:00
jesopo
4d41848b57 Also use docstrings to check if a command has help available, allow one-string
denotation of multiple event hooks
2018-09-26 18:26:29 +01:00
jesopo
ebc77fa501 Support using docstrings as command help 2018-09-26 15:58:16 +01:00
jesopo
ecb9d7cb3f Move most code in root directory to src/ 2018-09-24 15:13:27 +01:00
dngfx
febb6d66e3 font reset at the beginning of commands to stop wonkiness with highlighting and fix duck decoys. 2018-09-22 19:10:52 +01:00
jesopo
a87196c608 Change Utils.color to take a string to wrap in color 2018-09-21 11:39:09 +01:00
jesopo
fcbb7c960c Refactor everything to use delimited events 2018-09-19 13:25:12 +01:00
jesopo
f3d8d35083 Send a FONT_RESET (\x0F) after stderr module names because a bug in weechat
pre-2.2 means that because red colors are displayed as red+bold, the second
FONT_COLOR (\x03) only resets the red coloring, not the bold, meaning the rest
of the line is bold.
2018-09-19 02:22:30 +01:00