mirror of
https://github.com/PluralKit/PluralKit.git
synced 2026-02-14 17:50:13 +00:00
feat: implement proper ("static") parameters handling command parser -> bot
feat: handle few more commands bot side fix(commands): handle missing parameters and return error refactor(commands): use ordermap instead of relying on a sort function to sort tokens
This commit is contained in:
parent
1a781014bd
commit
eec9f64026
16 changed files with 358 additions and 502 deletions
|
|
@ -6,8 +6,21 @@ interface CommandResult {
|
|||
Ok(ParsedCommand command);
|
||||
Err(string error);
|
||||
};
|
||||
[Enum]
|
||||
interface ParameterKind {
|
||||
MemberRef();
|
||||
SystemRef();
|
||||
MemberPrivacyTarget();
|
||||
PrivacyLevel();
|
||||
OpaqueString();
|
||||
};
|
||||
dictionary Parameter {
|
||||
string raw;
|
||||
ParameterKind kind;
|
||||
};
|
||||
dictionary ParsedCommand {
|
||||
string command_ref;
|
||||
sequence<string> args;
|
||||
record<string, Parameter> params;
|
||||
record<string, string?> flags;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue