reciple 6.0.0-dev.17 → 6.0.0-dev.19

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (46) hide show
  1. package/LICENSE +674 -674
  2. package/README.md +183 -183
  3. package/dist/lib/bin.mjs +65 -63
  4. package/dist/lib/esm.mjs +1 -1
  5. package/dist/lib/index.js +35 -35
  6. package/dist/lib/reciple/classes/RecipleClient.js +296 -300
  7. package/dist/lib/reciple/classes/RecipleConfig.js +106 -106
  8. package/dist/lib/reciple/classes/RecipleModule.js +94 -94
  9. package/dist/lib/reciple/classes/builders/MessageCommandBuilder.js +242 -242
  10. package/dist/lib/reciple/classes/builders/MessageCommandOptionBuilder.js +85 -85
  11. package/dist/lib/reciple/classes/builders/SlashCommandBuilder.js +216 -216
  12. package/dist/lib/reciple/classes/managers/ApplicationCommandManager.js +172 -172
  13. package/dist/lib/reciple/classes/managers/ClientCommandManager.js +62 -62
  14. package/dist/lib/reciple/classes/managers/ClientModuleManager.js +183 -183
  15. package/dist/lib/reciple/classes/managers/CommandCooldownManager.js +100 -100
  16. package/dist/lib/reciple/classes/managers/MessageCommandOptionManager.js +25 -25
  17. package/dist/lib/reciple/flags.js +31 -31
  18. package/dist/lib/reciple/permissions.js +30 -30
  19. package/dist/lib/reciple/types/builders.js +11 -11
  20. package/dist/lib/reciple/types/commands.js +15 -15
  21. package/dist/lib/reciple/types/paramOptions.js +2 -2
  22. package/dist/lib/reciple/util.js +68 -66
  23. package/dist/lib/reciple/version.js +47 -47
  24. package/dist/types/bin.d.mts +2 -2
  25. package/dist/types/esm.d.mts +1 -1
  26. package/dist/types/index.d.ts +19 -19
  27. package/dist/types/reciple/classes/RecipleClient.d.ts +103 -103
  28. package/dist/types/reciple/classes/RecipleConfig.d.ts +100 -100
  29. package/dist/types/reciple/classes/RecipleModule.d.ts +56 -56
  30. package/dist/types/reciple/classes/builders/MessageCommandBuilder.d.ts +150 -150
  31. package/dist/types/reciple/classes/builders/MessageCommandOptionBuilder.d.ts +43 -43
  32. package/dist/types/reciple/classes/builders/SlashCommandBuilder.d.ts +88 -88
  33. package/dist/types/reciple/classes/managers/ApplicationCommandManager.d.ts +51 -51
  34. package/dist/types/reciple/classes/managers/ClientCommandManager.d.ts +37 -37
  35. package/dist/types/reciple/classes/managers/ClientModuleManager.d.ts +49 -49
  36. package/dist/types/reciple/classes/managers/CommandCooldownManager.d.ts +70 -70
  37. package/dist/types/reciple/classes/managers/MessageCommandOptionManager.d.ts +22 -22
  38. package/dist/types/reciple/flags.d.ts +17 -17
  39. package/dist/types/reciple/permissions.d.ts +19 -19
  40. package/dist/types/reciple/types/builders.d.ts +197 -197
  41. package/dist/types/reciple/types/commands.d.ts +81 -81
  42. package/dist/types/reciple/types/paramOptions.d.ts +101 -101
  43. package/dist/types/reciple/util.d.ts +23 -20
  44. package/dist/types/reciple/version.d.ts +25 -25
  45. package/package.json +2 -2
  46. package/resource/reciple.yml +120 -120
@@ -1,51 +1,51 @@
1
- import { ApplicationCommand, ApplicationCommandData, ContextMenuCommandBuilder, GuildResolvable, RestOrArray, RESTPostAPIApplicationCommandsJSONBody, SlashCommandBuilder as DiscordJsSlashCommandBuilder } from 'discord.js';
2
- import { AnySlashCommandBuilder } from '../../types/builders';
3
- import { RecipleClient } from '../RecipleClient';
4
- export declare type ApplicationCommandBuilder = AnySlashCommandBuilder | ContextMenuCommandBuilder | DiscordJsSlashCommandBuilder;
5
- export declare class ApplicationCommandManager {
6
- readonly client: RecipleClient;
7
- constructor(client: RecipleClient);
8
- /**
9
- * Sets application commands globally or in guilds
10
- * @param commands Application commands
11
- * @param guilds set only to guilds
12
- */
13
- set(commands: (ApplicationCommandBuilder | ApplicationCommandData)[], ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
14
- /**
15
- * Add command globally or in guilds
16
- * @param command Application command
17
- * @param guilds add only in guilds
18
- */
19
- add(command: ApplicationCommandBuilder | ApplicationCommandData, ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
20
- /**
21
- * Remove application command globally or in guilds
22
- * @param command id of application commmand or ApplicationCommand class
23
- * @param guilds Remove from guilds
24
- */
25
- remove(command: string | ApplicationCommand, ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
26
- /**
27
- * Edit application command globally or in guilds
28
- * @param command id of application command or ApplicationCommand class
29
- * @param newCommand new application command data
30
- * @param guilds Edit only from guilds
31
- */
32
- edit(command: string | ApplicationCommand, newCommand: ApplicationCommandBuilder | ApplicationCommandData, ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
33
- /**
34
- * Get application command from cache by application command data, builder, id, or name globally or from guid
35
- * @param command application command data, builder, id, or name
36
- * @param guild get command from guild
37
- */
38
- get(command: ApplicationCommandData | ApplicationCommandBuilder | string, guild?: GuildResolvable): ApplicationCommand | undefined;
39
- /**
40
- * Fetch application command by id globally or from guild
41
- * @param commandId command id
42
- * @param guild fetch from guild
43
- */
44
- fetch(commandId: string, guild?: GuildResolvable): Promise<ApplicationCommand>;
45
- /**
46
- * Parse application command builders to command data
47
- * @param commands Application command builders
48
- * @param setPermissions set slash commands permissions
49
- */
50
- protected parseCommands(commands: (ApplicationCommandData | ApplicationCommandBuilder | RESTPostAPIApplicationCommandsJSONBody)[], setPermissions?: boolean): (ApplicationCommandData | RESTPostAPIApplicationCommandsJSONBody)[];
51
- }
1
+ import { ApplicationCommand, ApplicationCommandData, ContextMenuCommandBuilder, GuildResolvable, RestOrArray, RESTPostAPIApplicationCommandsJSONBody, SlashCommandBuilder as DiscordJsSlashCommandBuilder } from 'discord.js';
2
+ import { AnySlashCommandBuilder } from '../../types/builders';
3
+ import { RecipleClient } from '../RecipleClient';
4
+ export declare type ApplicationCommandBuilder = AnySlashCommandBuilder | ContextMenuCommandBuilder | DiscordJsSlashCommandBuilder;
5
+ export declare class ApplicationCommandManager {
6
+ readonly client: RecipleClient;
7
+ constructor(client: RecipleClient);
8
+ /**
9
+ * Sets application commands globally or in guilds
10
+ * @param commands Application commands
11
+ * @param guilds set only to guilds
12
+ */
13
+ set(commands: (ApplicationCommandBuilder | ApplicationCommandData)[], ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
14
+ /**
15
+ * Add command globally or in guilds
16
+ * @param command Application command
17
+ * @param guilds add only in guilds
18
+ */
19
+ add(command: ApplicationCommandBuilder | ApplicationCommandData, ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
20
+ /**
21
+ * Remove application command globally or in guilds
22
+ * @param command id of application commmand or ApplicationCommand class
23
+ * @param guilds Remove from guilds
24
+ */
25
+ remove(command: string | ApplicationCommand, ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
26
+ /**
27
+ * Edit application command globally or in guilds
28
+ * @param command id of application command or ApplicationCommand class
29
+ * @param newCommand new application command data
30
+ * @param guilds Edit only from guilds
31
+ */
32
+ edit(command: string | ApplicationCommand, newCommand: ApplicationCommandBuilder | ApplicationCommandData, ...guilds: RestOrArray<GuildResolvable>): Promise<void>;
33
+ /**
34
+ * Get application command from cache by application command data, builder, id, or name globally or from guid
35
+ * @param command application command data, builder, id, or name
36
+ * @param guild get command from guild
37
+ */
38
+ get(command: ApplicationCommandData | ApplicationCommandBuilder | string, guild?: GuildResolvable): ApplicationCommand | undefined;
39
+ /**
40
+ * Fetch application command by id globally or from guild
41
+ * @param commandId command id
42
+ * @param guild fetch from guild
43
+ */
44
+ fetch(commandId: string, guild?: GuildResolvable): Promise<ApplicationCommand>;
45
+ /**
46
+ * Parse application command builders to command data
47
+ * @param commands Application command builders
48
+ * @param setPermissions set slash commands permissions
49
+ */
50
+ protected parseCommands(commands: (ApplicationCommandData | ApplicationCommandBuilder | RESTPostAPIApplicationCommandsJSONBody)[], setPermissions?: boolean): (ApplicationCommandData | RESTPostAPIApplicationCommandsJSONBody)[];
51
+ }
@@ -1,37 +1,37 @@
1
- import { ApplicationCommandData, Collection, GuildResolvable, RestOrArray } from 'discord.js';
2
- import { AnyCommandBuilder, AnyCommandData, AnySlashCommandBuilder, CommandType, MessageCommandData, SlashCommandData } from '../../types/builders';
3
- import { MessageCommandBuilder } from '../builders/MessageCommandBuilder';
4
- import { SlashCommandBuilder } from '../builders/SlashCommandBuilder';
5
- import { RecipleClient } from '../RecipleClient';
6
- import { ApplicationCommandBuilder } from './ApplicationCommandManager';
7
- export interface ClientCommandManagerOptions {
8
- client: RecipleClient;
9
- messageCommands?: (MessageCommandBuilder | MessageCommandData)[];
10
- slashCommands?: (AnySlashCommandBuilder | SlashCommandData)[];
11
- }
12
- export declare class ClientCommandManager {
13
- readonly client: RecipleClient;
14
- readonly slashCommands: Collection<string, AnySlashCommandBuilder>;
15
- readonly messageCommands: Collection<string, MessageCommandBuilder>;
16
- readonly additionalApplicationCommands: (ApplicationCommandBuilder | ApplicationCommandData)[];
17
- get applicationCommandsSize(): number;
18
- constructor(options: ClientCommandManagerOptions);
19
- /**
20
- * Add command to command manager
21
- * @param commands Any command data or builder
22
- */
23
- add(...commands: RestOrArray<AnyCommandBuilder | AnyCommandData>): this;
24
- /**
25
- * Get command builder by name or alias if it's a message command
26
- * @param command Command name
27
- * @param type Command type
28
- */
29
- get(command: string, type?: undefined): AnyCommandBuilder | undefined;
30
- get(command: string, type?: CommandType.MessageCommand): MessageCommandBuilder | undefined;
31
- get(command: string, type?: CommandType.SlashCommand): SlashCommandBuilder | undefined;
32
- /**
33
- * Register application commands
34
- * @param guilds Register application commands to guilds
35
- */
36
- registerApplicationCommands(...guilds: RestOrArray<GuildResolvable>): Promise<this>;
37
- }
1
+ import { ApplicationCommandData, Collection, GuildResolvable, RestOrArray } from 'discord.js';
2
+ import { AnyCommandBuilder, AnyCommandData, AnySlashCommandBuilder, CommandType, MessageCommandData, SlashCommandData } from '../../types/builders';
3
+ import { MessageCommandBuilder } from '../builders/MessageCommandBuilder';
4
+ import { SlashCommandBuilder } from '../builders/SlashCommandBuilder';
5
+ import { RecipleClient } from '../RecipleClient';
6
+ import { ApplicationCommandBuilder } from './ApplicationCommandManager';
7
+ export interface ClientCommandManagerOptions {
8
+ client: RecipleClient;
9
+ messageCommands?: (MessageCommandBuilder | MessageCommandData)[];
10
+ slashCommands?: (AnySlashCommandBuilder | SlashCommandData)[];
11
+ }
12
+ export declare class ClientCommandManager {
13
+ readonly client: RecipleClient;
14
+ readonly slashCommands: Collection<string, AnySlashCommandBuilder>;
15
+ readonly messageCommands: Collection<string, MessageCommandBuilder>;
16
+ readonly additionalApplicationCommands: (ApplicationCommandBuilder | ApplicationCommandData)[];
17
+ get applicationCommandsSize(): number;
18
+ constructor(options: ClientCommandManagerOptions);
19
+ /**
20
+ * Add command to command manager
21
+ * @param commands Any command data or builder
22
+ */
23
+ add(...commands: RestOrArray<AnyCommandBuilder | AnyCommandData>): this;
24
+ /**
25
+ * Get command builder by name or alias if it's a message command
26
+ * @param command Command name
27
+ * @param type Command type
28
+ */
29
+ get(command: string, type?: undefined): AnyCommandBuilder | undefined;
30
+ get(command: string, type?: CommandType.MessageCommand): MessageCommandBuilder | undefined;
31
+ get(command: string, type?: CommandType.SlashCommand): SlashCommandBuilder | undefined;
32
+ /**
33
+ * Register application commands
34
+ * @param guilds Register application commands to guilds
35
+ */
36
+ registerApplicationCommands(...guilds: RestOrArray<GuildResolvable>): Promise<this>;
37
+ }
@@ -1,49 +1,49 @@
1
- import { Collection } from 'discord.js';
2
- import { ClientModuleManagerGetModulePathsOptions, ClientModuleManagerLoadModulesOptions, ClientModuleManagerResolveModuleFilesOptions, ClientModuleManagerStartModulesOptions, ClientModuleManagerUnloadModulesOptions } from '../../types/paramOptions';
3
- import { RecipleClient } from '../RecipleClient';
4
- import { RecipleModule, RecipleScript } from '../RecipleModule';
5
- export interface ClientModuleManagerOptions {
6
- client: RecipleClient;
7
- modules?: (RecipleModule | RecipleScript)[];
8
- }
9
- export declare class ClientModuleManager {
10
- readonly client: RecipleClient;
11
- readonly modules: Collection<string, RecipleModule>;
12
- constructor(options: ClientModuleManagerOptions);
13
- /**
14
- * Start modules
15
- * @param options start modules options
16
- * @returns started modules
17
- */
18
- startModules(options: ClientModuleManagerStartModulesOptions): Promise<RecipleModule[]>;
19
- /**
20
- * Load modules
21
- * @param options load modules options
22
- * @returns loaded modules
23
- */
24
- loadModules(options?: ClientModuleManagerLoadModulesOptions): Promise<RecipleModule[]>;
25
- /**
26
- * Unload modules
27
- * @param options unload modules options
28
- * @returns unloaded modules
29
- */
30
- unloadModules(options?: ClientModuleManagerUnloadModulesOptions): Promise<RecipleModule[]>;
31
- /**
32
- * Resolve modules from file paths
33
- * @param options resolve module files options
34
- * @returns resolved modules
35
- */
36
- resolveModuleFiles(options: ClientModuleManagerResolveModuleFilesOptions): Promise<RecipleModule[]>;
37
- /**
38
- * Validate module script
39
- * @param script module script
40
- * @returns `true` if script is valid
41
- */
42
- static validateScript(script: unknown): script is RecipleScript;
43
- /**
44
- * Get module file paths from folders
45
- * @param options get module paths options
46
- * @returns module paths
47
- */
48
- getModulePaths(options?: ClientModuleManagerGetModulePathsOptions): Promise<string[]>;
49
- }
1
+ import { Collection } from 'discord.js';
2
+ import { ClientModuleManagerGetModulePathsOptions, ClientModuleManagerLoadModulesOptions, ClientModuleManagerResolveModuleFilesOptions, ClientModuleManagerStartModulesOptions, ClientModuleManagerUnloadModulesOptions } from '../../types/paramOptions';
3
+ import { RecipleClient } from '../RecipleClient';
4
+ import { RecipleModule, RecipleScript } from '../RecipleModule';
5
+ export interface ClientModuleManagerOptions {
6
+ client: RecipleClient;
7
+ modules?: (RecipleModule | RecipleScript)[];
8
+ }
9
+ export declare class ClientModuleManager {
10
+ readonly client: RecipleClient;
11
+ readonly modules: Collection<string, RecipleModule>;
12
+ constructor(options: ClientModuleManagerOptions);
13
+ /**
14
+ * Start modules
15
+ * @param options start modules options
16
+ * @returns started modules
17
+ */
18
+ startModules(options: ClientModuleManagerStartModulesOptions): Promise<RecipleModule[]>;
19
+ /**
20
+ * Load modules
21
+ * @param options load modules options
22
+ * @returns loaded modules
23
+ */
24
+ loadModules(options?: ClientModuleManagerLoadModulesOptions): Promise<RecipleModule[]>;
25
+ /**
26
+ * Unload modules
27
+ * @param options unload modules options
28
+ * @returns unloaded modules
29
+ */
30
+ unloadModules(options?: ClientModuleManagerUnloadModulesOptions): Promise<RecipleModule[]>;
31
+ /**
32
+ * Resolve modules from file paths
33
+ * @param options resolve module files options
34
+ * @returns resolved modules
35
+ */
36
+ resolveModuleFiles(options: ClientModuleManagerResolveModuleFilesOptions): Promise<RecipleModule[]>;
37
+ /**
38
+ * Validate module script
39
+ * @param script module script
40
+ * @returns `true` if script is valid
41
+ */
42
+ static validateScript(script: unknown): script is RecipleScript;
43
+ /**
44
+ * Get module file paths from folders
45
+ * @param options get module paths options
46
+ * @returns module paths
47
+ */
48
+ getModulePaths(options?: ClientModuleManagerGetModulePathsOptions): Promise<string[]>;
49
+ }
@@ -1,70 +1,70 @@
1
- import { Guild, RestOrArray, TextBasedChannel, User } from 'discord.js';
2
- import { CommandType } from '../../types/builders';
3
- /**
4
- * cooled-down user object interface
5
- */
6
- export interface CooledDownUser {
7
- /**
8
- * Cooled-down user
9
- */
10
- user: User;
11
- /**
12
- * Cooled-down command name
13
- */
14
- command: string;
15
- /**
16
- * Command type
17
- */
18
- type: CommandType;
19
- /**
20
- * In guild
21
- */
22
- guild?: Guild | null;
23
- /**
24
- * Cooled-down channel
25
- */
26
- channel?: TextBasedChannel;
27
- /**
28
- * Cooldown expiration
29
- */
30
- expireTime: number;
31
- }
32
- /**
33
- * cooled-down users manager
34
- */
35
- export declare class CommandCooldownManager extends Array<CooledDownUser> {
36
- constructor(...data: RestOrArray<CooledDownUser>);
37
- /**
38
- * Alias for `CommandCooldownManager#push()`
39
- * @param options Cooled-down user data
40
- */
41
- add(...options: CooledDownUser[]): number;
42
- /**
43
- * Remove cooldown from specific user, channel or guild
44
- * @param options Remove cooldown data options
45
- * @param limit Remove cooldown data limit
46
- * @returns Returns the removed values
47
- */
48
- remove(options: Partial<CooledDownUser>, limit?: number): CooledDownUser[];
49
- /**
50
- * Check if the given user is cooled-down
51
- * @param options Options to identify if user is on cooldown
52
- */
53
- isCooledDown(options: Partial<Omit<CooledDownUser, 'expireTime'>>): boolean;
54
- /**
55
- * Purge non cooled-down users from this array
56
- * @param options Clean cooldown options
57
- */
58
- clean(options?: Partial<Omit<CooledDownUser, 'expireTime'>>): void;
59
- /**
60
- * Get someone's cooldown data
61
- * @param options Get cooldown data options
62
- */
63
- get(options: Partial<Omit<CooledDownUser, 'expireTime'>>): CooledDownUser | undefined;
64
- /**
65
- * Check if the options are valid
66
- * @param options Options to validated
67
- * @param data Cooled-down user data
68
- */
69
- static checkOptions(options: Partial<Omit<CooledDownUser, 'expireTime'>>, data: CooledDownUser): boolean;
70
- }
1
+ import { Guild, RestOrArray, TextBasedChannel, User } from 'discord.js';
2
+ import { CommandType } from '../../types/builders';
3
+ /**
4
+ * cooled-down user object interface
5
+ */
6
+ export interface CooledDownUser {
7
+ /**
8
+ * Cooled-down user
9
+ */
10
+ user: User;
11
+ /**
12
+ * Cooled-down command name
13
+ */
14
+ command: string;
15
+ /**
16
+ * Command type
17
+ */
18
+ type: CommandType;
19
+ /**
20
+ * In guild
21
+ */
22
+ guild?: Guild | null;
23
+ /**
24
+ * Cooled-down channel
25
+ */
26
+ channel?: TextBasedChannel;
27
+ /**
28
+ * Cooldown expiration
29
+ */
30
+ expireTime: number;
31
+ }
32
+ /**
33
+ * cooled-down users manager
34
+ */
35
+ export declare class CommandCooldownManager extends Array<CooledDownUser> {
36
+ constructor(...data: RestOrArray<CooledDownUser>);
37
+ /**
38
+ * Alias for `CommandCooldownManager#push()`
39
+ * @param options Cooled-down user data
40
+ */
41
+ add(...options: CooledDownUser[]): number;
42
+ /**
43
+ * Remove cooldown from specific user, channel or guild
44
+ * @param options Remove cooldown data options
45
+ * @param limit Remove cooldown data limit
46
+ * @returns Returns the removed values
47
+ */
48
+ remove(options: Partial<CooledDownUser>, limit?: number): CooledDownUser[];
49
+ /**
50
+ * Check if the given user is cooled-down
51
+ * @param options Options to identify if user is on cooldown
52
+ */
53
+ isCooledDown(options: Partial<Omit<CooledDownUser, 'expireTime'>>): boolean;
54
+ /**
55
+ * Purge non cooled-down users from this array
56
+ * @param options Clean cooldown options
57
+ */
58
+ clean(options?: Partial<Omit<CooledDownUser, 'expireTime'>>): void;
59
+ /**
60
+ * Get someone's cooldown data
61
+ * @param options Get cooldown data options
62
+ */
63
+ get(options: Partial<Omit<CooledDownUser, 'expireTime'>>): CooledDownUser | undefined;
64
+ /**
65
+ * Check if the options are valid
66
+ * @param options Options to validated
67
+ * @param data Cooled-down user data
68
+ */
69
+ static checkOptions(options: Partial<Omit<CooledDownUser, 'expireTime'>>, data: CooledDownUser): boolean;
70
+ }
@@ -1,22 +1,22 @@
1
- import { MessageCommandValidatedOption } from '../builders/MessageCommandBuilder';
2
- import { RestOrArray } from 'discord.js';
3
- /**
4
- * Validated message options manager
5
- */
6
- export declare class MessageCommandOptionManager extends Array<MessageCommandValidatedOption> {
7
- constructor(...data: RestOrArray<MessageCommandValidatedOption>);
8
- /**
9
- * Get the option info
10
- * @param name Option name
11
- * @param requied Is the option required
12
- */
13
- get(name: string, requied: true): MessageCommandValidatedOption;
14
- get(name: string, requied?: boolean): MessageCommandValidatedOption | null;
15
- /**
16
- * Get the option value
17
- * @param name Option name
18
- * @param requied Is the option required
19
- */
20
- getValue(name: string, requied: true): string;
21
- getValue(name: string, requied?: boolean): string | null;
22
- }
1
+ import { MessageCommandValidatedOption } from '../builders/MessageCommandBuilder';
2
+ import { RestOrArray } from 'discord.js';
3
+ /**
4
+ * Validated message options manager
5
+ */
6
+ export declare class MessageCommandOptionManager extends Array<MessageCommandValidatedOption> {
7
+ constructor(...data: RestOrArray<MessageCommandValidatedOption>);
8
+ /**
9
+ * Get the option info
10
+ * @param name Option name
11
+ * @param requied Is the option required
12
+ */
13
+ get(name: string, requied: true): MessageCommandValidatedOption;
14
+ get(name: string, requied?: boolean): MessageCommandValidatedOption | null;
15
+ /**
16
+ * Get the option value
17
+ * @param name Option name
18
+ * @param requied Is the option required
19
+ */
20
+ getValue(name: string, requied: true): string;
21
+ getValue(name: string, requied?: boolean): string | null;
22
+ }
@@ -1,17 +1,17 @@
1
- import { Command } from 'commander';
2
- /**
3
- * Commander
4
- */
5
- export declare const commander: Command;
6
- /**
7
- * Used flags
8
- */
9
- export declare const flags: import("commander").OptionValues;
10
- /**
11
- * Token flag
12
- */
13
- export declare const token: string | undefined;
14
- /**
15
- * Current working directory
16
- */
17
- export declare const cwd: string;
1
+ import { Command } from 'commander';
2
+ /**
3
+ * Commander
4
+ */
5
+ export declare const commander: Command;
6
+ /**
7
+ * Used flags
8
+ */
9
+ export declare const flags: import("commander").OptionValues;
10
+ /**
11
+ * Token flag
12
+ */
13
+ export declare const token: string | undefined;
14
+ /**
15
+ * Current working directory
16
+ */
17
+ export declare const cwd: string;
@@ -1,19 +1,19 @@
1
- import { Guild, GuildTextBasedChannel, PermissionResolvable } from 'discord.js';
2
- import { UserHasCommandPermissionsOptions } from './types/paramOptions';
3
- /**
4
- * Check if the user has permissions to execute the given command name
5
- * @param options options
6
- */
7
- export declare function userHasCommandPermissions(options: UserHasCommandPermissionsOptions): boolean;
8
- /**
9
- * Check if the bot has the required permissions in a guild
10
- * @param guild Check if the bot has the required permissions in this guild
11
- * @param requiredPermissions Required guild bot permissions
12
- */
13
- export declare function botHasExecutePermissions(guild?: Guild, requiredPermissions?: PermissionResolvable[]): boolean;
14
- /**
15
- * Check if the bot has the required permissions in a channel
16
- * @param channel Check if the bot has the required permissions in this channel
17
- * @param requiredPermissions Required guild bot permissions
18
- */
19
- export declare function botHasExecutePermissions(channel?: GuildTextBasedChannel, requiredPermissions?: PermissionResolvable[]): boolean;
1
+ import { Guild, GuildTextBasedChannel, PermissionResolvable } from 'discord.js';
2
+ import { UserHasCommandPermissionsOptions } from './types/paramOptions';
3
+ /**
4
+ * Check if the user has permissions to execute the given command name
5
+ * @param options options
6
+ */
7
+ export declare function userHasCommandPermissions(options: UserHasCommandPermissionsOptions): boolean;
8
+ /**
9
+ * Check if the bot has the required permissions in a guild
10
+ * @param guild Check if the bot has the required permissions in this guild
11
+ * @param requiredPermissions Required guild bot permissions
12
+ */
13
+ export declare function botHasExecutePermissions(guild?: Guild, requiredPermissions?: PermissionResolvable[]): boolean;
14
+ /**
15
+ * Check if the bot has the required permissions in a channel
16
+ * @param channel Check if the bot has the required permissions in this channel
17
+ * @param requiredPermissions Required guild bot permissions
18
+ */
19
+ export declare function botHasExecutePermissions(channel?: GuildTextBasedChannel, requiredPermissions?: PermissionResolvable[]): boolean;