1
0
Fork 0
mirror of https://github.com/diamondburned/arikawa.git synced 2024-11-01 04:24:19 +00:00
Commit graph

44 commits

Author SHA1 Message Date
diamondburned 76c25835b7
bot: Move bot to utils 2021-09-18 00:39:34 -07:00
diamondburned 17dbccccc3 bot: Clarify unexported *Context field 2021-06-22 16:10:30 -07:00
Maximilian von Lindern 2875635532 bot: remove deprecated Subcommand.SanitizeMessage 2021-06-06 13:12:02 -07:00
Samuel Hernandez 40e1a3757d *: Migrated Go Modules to v3 2021-06-01 19:59:01 -07:00
diamondburned 65d7b8765b Bot: Allow self-mentions; deprecate SanitizeMessage 2021-02-14 13:14:38 -08:00
diamondburned d13aa00a57 Bot: Fixed extra space in top-level comments 2021-02-07 17:21:16 -08:00
diamondburned b801e46760 Bot: Optional command when plumbed in Help, no more extra space 2020-12-14 14:18:04 -08:00
diamondburned 66c95761a7 Bot: Getter for Plumbed and Help generation fix 2020-12-14 13:43:36 -08:00
diamondburned 273fcf1418 Bot: Added subcommand aliases and better setup API
This commit adds subcommand aliases as well as additional code in
HelpGenerate to cover for both subcommand and command aliases.

A breaking change is that {,Must}RegisterSubcommandCustom methods are
now replaced with normal {,Must}RegisterSubcommand methods. This is
because they now use variadic strings, which could take 0, 1 or more
arguments.

This commit also allows AddMiddleware and similar methods to be given a
method directly:

    sub.Plumb(cmds.PlumbedHandler)
    sub.AddMiddleware(cmds.PlumbedHandler, cmds.plumbMiddleware)

This change closes issue #146.
2020-11-12 19:02:52 -08:00
diamondburned 9899f6073b Bot: Added automatic Intents detection from handlers
This commit adds automatic Intents detection into package bot. When the
Start function is used, the intents will be OR'd after running the
options callback.

This commit also breaks the old "AddIntent" methods to rename them to
"AddIntents" for correctness.
2020-10-28 22:49:18 -07:00
diamondburned 75df94d9f4 *: Migrated Go Modules to v2 2020-10-28 15:39:59 -07:00
diamondburned d888a5a7ac Bot: Added better middleware documentation 2020-08-11 17:31:29 -07:00
Maximilian von Lindern 1585797b52 *: Linting and typo fixes (#134)
* Linting and typo fixes

* Linting and typo fixes

* revert comma fix
2020-07-29 16:58:33 -07:00
diamondburned 56b1a7cce8 Bot: Help generators now allow generating hidden commands 2020-07-14 16:33:21 -07:00
ks129 93fbfd98d0 Fix aliases appending
Add 3 dots on appending to merge 2 slices.
2020-05-24 23:08:55 -07:00
ks129 23d97044ec Simplify aliases adding
- Removed duplicates check
- Fixed docstring
2020-05-24 23:08:55 -07:00
ks129 75fe1bd03a Implement command aliases
- Add alias parsing to `Context.findCommand`.
- Add new function to `Subcommand`: `AddAliases` that add new alias(es) to command.
- Added `Aliases` property to `MethodContext`
2020-05-24 23:08:55 -07:00
mavolin 41ce1f389e
make all error messages lowercase 2020-05-16 23:14:49 +02:00
diamondburned 795a69ca7d Bot: Added EditableCommands 2020-05-14 18:52:15 -07:00
diamondburned 729979088c Bot: Added more tests and the Help API 2020-05-14 14:04:18 -07:00
diamondburned (Forefront) 67430c6d7a Bot: Added Plumb support, fixed tests
Merged

Merged
2020-05-14 13:59:17 -07:00
diamondburned (Forefront) 964e8cdf13 Bot: Partially implemented middlewares 2020-05-14 13:59:17 -07:00
diamondburned (Forefront) cf48bd8543 Bot: Variadic arguments are now ellipsized in help 2020-05-03 18:35:51 -07:00
diamondburned (Forefront) b122aa6561 Bot: Added trailing manual parser support 2020-05-03 18:33:24 -07:00
diamondburned (Forefront) 3b903dce68 Bot: Added variadic arguments support 2020-05-03 15:59:10 -07:00
diamondburned (Forefront) e0a002cc6d Bot: Descriptions now show next to arguments 2020-04-10 20:17:55 -07:00
diamondburned (Forefront) 06136b7d5f Websocket: Replaced Conn's mutices with channels 2020-04-10 20:03:52 -07:00
diamondburned (Forefront) aa53661b60 Bot: Prettier help formatting 2020-04-09 23:10:21 -07:00
diamondburned (Forefront) cc530ce7a2 Bot: Allow func(T), added more documentation, minor fixes 2020-04-09 13:49:12 -07:00
diamondburned (Forefront) 922c32c0eb Bot: Added FindCommand 2020-04-08 23:06:46 -07:00
diamondburned (Forefront) 3ee307b788 Bot: Added Usager, improved help 2020-04-08 21:25:50 -07:00
diamondburned (Forefront) 09ae9fbb07 Bot: Added a Prefixer API which breaks the old Prefix string API 2020-04-06 13:27:33 -07:00
diamondburned (Forefront) 3770927a48 Bot: trivial fixes 2020-01-28 16:01:39 -08:00
diamondburned (Forefront) 1c25ccbf8e Bot: added data return types 2020-01-26 01:06:54 -08:00
diamondburned (Forefront) 77729ead48 Bot: fixed bug where subcommands with no visible commands would show 2020-01-25 22:26:08 -08:00
diamondburned (Forefront) 9d3528190f Bot: added Plumb flag, methods no longer need arguments be pointers 2020-01-25 21:43:42 -08:00
diamondburned (Forefront) 0304ffaeb0 Bot: added the Hidden nameflag 2020-01-25 14:30:15 -08:00
diamondburned (Forefront) 39e6188787 Bot: simplified Arguments of a CommandContext 2020-01-25 14:07:49 -08:00
diamondburned 367f445ee9 Fixed bugs in the bot package
Bugs include: Events not being called, inconsistent subcommand casing
2020-01-24 08:08:12 -08:00
diamondburned (Forefront) a5d817b28d Help subcommand method 2020-01-23 22:46:17 -08:00
diamondburned (Forefront) 3d81c28685 Commands are now camel-cased 2020-01-23 22:30:32 -08:00
diamondburned (Forefront) 3baf89671b Bot: Separated events from commands 2020-01-23 22:27:21 -08:00
diamondburned aadcbd0767
Added middleware features into package bot. (#3)
* Middleware nameflag
* Completed M-Middleware feature
* Changed Namer/Descriptor API to CanSetup API
2020-01-23 19:17:03 -08:00
diamondburned (Forefront) 28228a60f5 Ported rfrouter over 2020-01-18 22:06:00 -08:00