Commit graph

98 commits

Author SHA1 Message Date
jesopo
a501fdea1f Stop processing a command when we've decided the user doesn't have permission
(commands.py)
2019-01-29 15:38:04 +00:00
jesopo
7937be5128 Don't double up command prefix in !usage output (commands.py) 2019-01-29 08:36:47 +00:00
jesopo
f97c1f02fd Actually show the command prefix we now pass to _get_usage (commands.py) 2019-01-29 08:33:32 +00:00
jesopo
79ff20b66a Show command prefix in usage strings (commands.py) 2019-01-29 08:32:22 +00:00
jesopo
5d47e7e895 Add a permission to !ghwebhook so an admin user can use it without +o (github) 2019-01-29 08:06:59 +00:00
jesopo
549332db38 Check a return is truthy before we decide it's an error (command.py) 2019-01-28 23:57:12 +00:00
jesopo
ee1770cc08 Typo, force_success -> force_success = False (commands.py) 2019-01-28 23:52:30 +00:00
jesopo
d10a6d94c1 Add a way to force success and force failure of a command permission check
(commands.py)
2019-01-28 23:29:52 +00:00
jesopo
335f1545a8 Give StdOut.send the new method param (commands.py) 2019-01-25 07:11:45 +00:00
jesopo
26603c23ac Also pass method to StdOut/StdErr Send() when a send.stdout or
`send.stderr` event is sent (commands.py)
2019-01-23 21:39:05 +00:00
jesopo
64cb723901 Move logic to get command-method out of Out object (commands.py) 2019-01-23 20:35:28 +00:00
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