diskernel 0.1.23 → 0.1.25
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.
- package/dist/core/client.js +11 -13
- package/dist/core/command.d.ts.map +1 -1
- package/dist/core/command.js +52 -25
- package/dist/core/config.d.ts.map +1 -1
- package/dist/core/config.js +1 -8
- package/dist/core/logger.d.ts.map +1 -1
- package/dist/core/logger.js +12 -12
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +9 -1
- package/dist/types/command.d.ts.map +1 -1
- package/dist/types/command.js +0 -1
- package/dist/types/config.d.ts.map +1 -1
- package/package.json +1 -1
package/dist/core/client.js
CHANGED
|
@@ -39,24 +39,22 @@ export class Core extends core {
|
|
|
39
39
|
});
|
|
40
40
|
Logger.info("▶ Logging in to Discord...");
|
|
41
41
|
Logger.trace(`Using token: ${Config.get("TOKEN").replace(/.(?=.{4})/g, "*")}`);
|
|
42
|
-
await this.client
|
|
43
|
-
.login(Config.get("TOKEN"))
|
|
44
|
-
.catch((e) => {
|
|
42
|
+
await this.client.login(Config.get("TOKEN")).catch((e) => {
|
|
45
43
|
Logger.error("❌ Failed to login to Discord.");
|
|
46
44
|
ErrorHandler.fatal("Failed to login to Discord", e);
|
|
47
45
|
});
|
|
48
|
-
this.client.once("clientReady", () => {
|
|
46
|
+
this.client.once("clientReady", async () => {
|
|
49
47
|
Logger.info(`✅ Logged in as ${Core.client.user?.tag}`);
|
|
48
|
+
Logger.info("▶ Initializing commands...");
|
|
49
|
+
await Command.initialize();
|
|
50
|
+
Logger.info("✅ Commands initialized successfully.");
|
|
51
|
+
Logger.info("▶ Initializing events...");
|
|
52
|
+
if (!this.client) {
|
|
53
|
+
throw new DiskernelError("Discord client is not initialized before events.");
|
|
54
|
+
}
|
|
55
|
+
await Event.initalize(this.client);
|
|
56
|
+
Logger.info("✅ Events initialized successfully.");
|
|
50
57
|
});
|
|
51
|
-
Logger.info("▶ Initializing commands...");
|
|
52
|
-
await Command.initialize();
|
|
53
|
-
Logger.info("✅ Commands initialized successfully.");
|
|
54
|
-
Logger.info("▶ Initializing events...");
|
|
55
|
-
if (!this.client) {
|
|
56
|
-
throw new DiskernelError("Discord client is not initialized before events.");
|
|
57
|
-
}
|
|
58
|
-
await Event.initalize(this.client);
|
|
59
|
-
Logger.info("✅ Events initialized successfully.");
|
|
60
58
|
}
|
|
61
59
|
static stop() {
|
|
62
60
|
Logger.info("▶ Stopping Bot...");
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../src/core/command.ts"],"names":[],"mappings":"AAqBA,OAAO,EAML,OAAO,IAAI,OAAO,EAGnB,MAAM,mBAAmB,CAAC;AAI3B,qBAAa,OAAQ,SAAQ,OAAO;IAClC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,CAAS;IAC/B,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAqB;IAC5C,OAAO,CAAC,MAAM,CAAC,OAAO,
|
|
1
|
+
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../src/core/command.ts"],"names":[],"mappings":"AAqBA,OAAO,EAML,OAAO,IAAI,OAAO,EAGnB,MAAM,mBAAmB,CAAC;AAI3B,qBAAa,OAAQ,SAAQ,OAAO;IAClC,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,CAAS;IAC/B,OAAO,CAAC,MAAM,CAAC,QAAQ,CAAqB;IAC5C,OAAO,CAAC,MAAM,CAAC,OAAO,CAGlB;IACJ,OAAO,CAAC,MAAM,CAAC,WAAW,CAIjB;IACT,OAAO,CAAC,MAAM,CAAC,QAAQ,CAGnB;WAEgB,UAAU,IAAI,OAAO,CAAC,IAAI,CAAC;mBA0C1B,kBAAkB;IA0GvC,OAAO,CAAC,MAAM,CAAC,mBAAmB;IAyDlC,OAAO,CAAC,MAAM,CAAC,kBAAkB;IAcjC,OAAO,CAAC,MAAM,CAAC,aAAa;mBA8EP,mBAAmB;mBAqBnB,gBAAgB;IA6CrC,OAAO,CAAC,MAAM,CAAC,gBAAgB;IAkC/B,OAAO,CAAC,MAAM,CAAC,sBAAsB;IA6BrC,OAAO,CAAC,MAAM,CAAC,gBAAgB;mBA6BV,oBAAoB;mBA6BpB,qBAAqB;mBA2BrB,eAAe;mBA6Bf,cAAc;CA4HpC"}
|
package/dist/core/command.js
CHANGED
|
@@ -4,7 +4,7 @@ import { ApplicationCommandType, AutocompleteInteraction, ButtonInteraction, Cha
|
|
|
4
4
|
import { Core } from "./client.js";
|
|
5
5
|
import { Config } from "./config.js";
|
|
6
6
|
import { getCustomCoreLogger } from "./logger.js";
|
|
7
|
-
import { SlashCommandT, Command as command, BaseAction, BaseCommand } from "../types/index.js";
|
|
7
|
+
import { SlashCommandT, Command as command, BaseAction, BaseCommand, } from "../types/index.js";
|
|
8
8
|
const Logger = getCustomCoreLogger("commands");
|
|
9
9
|
export class Command extends command {
|
|
10
10
|
static client;
|
|
@@ -18,7 +18,14 @@ export class Command extends command {
|
|
|
18
18
|
this.subCommands = [];
|
|
19
19
|
this.cooldown = new Map();
|
|
20
20
|
this.client = Core.Client;
|
|
21
|
-
|
|
21
|
+
if (this.client?.isReady()) {
|
|
22
|
+
await this.registerCommands();
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
this.client?.once("ready", async () => {
|
|
26
|
+
await this.registerCommands();
|
|
27
|
+
});
|
|
28
|
+
}
|
|
22
29
|
this.client?.on("interactionCreate", (interaction) => {
|
|
23
30
|
if (interaction.isChatInputCommand() ||
|
|
24
31
|
interaction.isContextMenuCommand() ||
|
|
@@ -39,7 +46,7 @@ export class Command extends command {
|
|
|
39
46
|
})();
|
|
40
47
|
if (commands)
|
|
41
48
|
await this.registerWithGuildID(guild.id, commands.guild);
|
|
42
|
-
Logger.info(
|
|
49
|
+
Logger.info("✅ Register commands finished successfully.");
|
|
43
50
|
});
|
|
44
51
|
}
|
|
45
52
|
static async loadCommandFromDir(dir) {
|
|
@@ -131,39 +138,38 @@ export class Command extends command {
|
|
|
131
138
|
static buildCommandOptions(option, command) {
|
|
132
139
|
switch (option.type) {
|
|
133
140
|
case "string":
|
|
134
|
-
command.addStringOption((
|
|
141
|
+
command.addStringOption((optionBuilder) => optionBuilder
|
|
135
142
|
.setName(option.name)
|
|
136
143
|
.setDescription(option.description)
|
|
137
144
|
.setRequired(option.required)
|
|
138
|
-
.addChoices(option.choices ?? []));
|
|
145
|
+
.addChoices(...(option.choices ?? [])));
|
|
139
146
|
break;
|
|
140
147
|
case "integer":
|
|
141
|
-
command.addIntegerOption((
|
|
148
|
+
command.addIntegerOption((optionBuilder) => optionBuilder
|
|
142
149
|
.setName(option.name)
|
|
143
150
|
.setDescription(option.description)
|
|
144
|
-
.setRequired(option.required)
|
|
145
|
-
.addChoices(option.choices ?? []));
|
|
151
|
+
.setRequired(option.required));
|
|
146
152
|
break;
|
|
147
153
|
case "boolean":
|
|
148
|
-
command.addBooleanOption((
|
|
154
|
+
command.addBooleanOption((optionBuilder) => optionBuilder
|
|
149
155
|
.setName(option.name)
|
|
150
156
|
.setDescription(option.description)
|
|
151
157
|
.setRequired(option.required));
|
|
152
158
|
break;
|
|
153
159
|
case "channel":
|
|
154
|
-
command.addChannelOption((
|
|
160
|
+
command.addChannelOption((optionBuilder) => optionBuilder
|
|
155
161
|
.setName(option.name)
|
|
156
162
|
.setDescription(option.description)
|
|
157
163
|
.setRequired(option.required));
|
|
158
164
|
break;
|
|
159
165
|
case "role":
|
|
160
|
-
command.addRoleOption((
|
|
166
|
+
command.addRoleOption((optionBuilder) => optionBuilder
|
|
161
167
|
.setName(option.name)
|
|
162
168
|
.setDescription(option.description)
|
|
163
169
|
.setRequired(option.required));
|
|
164
170
|
break;
|
|
165
171
|
case "user":
|
|
166
|
-
command.addUserOption((
|
|
172
|
+
command.addUserOption((optionBuilder) => optionBuilder
|
|
167
173
|
.setName(option.name)
|
|
168
174
|
.setDescription(option.description)
|
|
169
175
|
.setRequired(option.required));
|
|
@@ -183,6 +189,7 @@ export class Command extends command {
|
|
|
183
189
|
const commands = [];
|
|
184
190
|
const globalCommands = [];
|
|
185
191
|
for (const command of this.commands) {
|
|
192
|
+
Logger.debug("Building command: {name}", { name: command.name });
|
|
186
193
|
if (command.type === "slash" && !command.parent) {
|
|
187
194
|
const slashCommand = new SlashCommandBuilder()
|
|
188
195
|
.setName(command.name)
|
|
@@ -208,9 +215,14 @@ export class Command extends command {
|
|
|
208
215
|
this.buildCommandOptions(option, subCommand);
|
|
209
216
|
}
|
|
210
217
|
}
|
|
211
|
-
this.subCommands.push({
|
|
218
|
+
this.subCommands.push({
|
|
219
|
+
parent: command.parent,
|
|
220
|
+
command: subCommand,
|
|
221
|
+
isGlobal: command.global,
|
|
222
|
+
});
|
|
212
223
|
}
|
|
213
|
-
else if (command.type === "userContextMenu" ||
|
|
224
|
+
else if (command.type === "userContextMenu" ||
|
|
225
|
+
command.type === "messageContextMenu") {
|
|
214
226
|
const contextMenuCommand = new ContextMenuCommandBuilder()
|
|
215
227
|
.setName(command.name)
|
|
216
228
|
.setType(command.type === "userContextMenu"
|
|
@@ -228,14 +240,16 @@ export class Command extends command {
|
|
|
228
240
|
}
|
|
229
241
|
}
|
|
230
242
|
this.subCommands.forEach((v) => {
|
|
231
|
-
const slashCommand = commands.find((c) => c.name === v.parent) ??
|
|
243
|
+
const slashCommand = commands.find((c) => c.name === v.parent) ??
|
|
244
|
+
globalCommands.find((c) => c.name === v.parent) ??
|
|
245
|
+
undefined;
|
|
232
246
|
if (slashCommand instanceof SlashCommandBuilder) {
|
|
233
247
|
slashCommand.addSubcommand(v.command);
|
|
234
248
|
}
|
|
235
249
|
});
|
|
236
250
|
return {
|
|
237
251
|
guild: commands.map((c) => c.toJSON()),
|
|
238
|
-
global: globalCommands.map(c => c.toJSON())
|
|
252
|
+
global: globalCommands.map((c) => c.toJSON()),
|
|
239
253
|
};
|
|
240
254
|
}
|
|
241
255
|
static async registerWithGuildID(guildID, commands) {
|
|
@@ -269,11 +283,12 @@ export class Command extends command {
|
|
|
269
283
|
})();
|
|
270
284
|
if (!commands)
|
|
271
285
|
return false;
|
|
272
|
-
const guilds = this.client.guilds.cache.values();
|
|
286
|
+
const guilds = Array.from(this.client.guilds.cache.values());
|
|
287
|
+
Logger.debug(`Current guild cache size: ${this.client.guilds.cache.size}`);
|
|
273
288
|
for (const guild of guilds) {
|
|
274
289
|
await this.registerWithGuildID(guild.id, commands.guild);
|
|
275
|
-
if (guilds.
|
|
276
|
-
|
|
290
|
+
if (guilds.length > 10) {
|
|
291
|
+
await new Promise((resolve) => setTimeout(resolve, 1000));
|
|
277
292
|
}
|
|
278
293
|
}
|
|
279
294
|
if (commands.global.length > 0) {
|
|
@@ -314,7 +329,8 @@ export class Command extends command {
|
|
|
314
329
|
interaction instanceof ModalSubmitInteraction
|
|
315
330
|
? interaction.customId
|
|
316
331
|
: interaction.commandName;
|
|
317
|
-
const command = this.commands.find((c) => c.name === interactionName) ||
|
|
332
|
+
const command = this.commands.find((c) => c.name === interactionName) ||
|
|
333
|
+
this.actions.get(interactionName);
|
|
318
334
|
if (!command)
|
|
319
335
|
return false;
|
|
320
336
|
if (!command.isAdminOnly)
|
|
@@ -331,7 +347,8 @@ export class Command extends command {
|
|
|
331
347
|
interaction instanceof ModalSubmitInteraction
|
|
332
348
|
? interaction.customId
|
|
333
349
|
: interaction.commandName;
|
|
334
|
-
const command = this.commands.find((c) => c.name === interactionName) ||
|
|
350
|
+
const command = this.commands.find((c) => c.name === interactionName) ||
|
|
351
|
+
this.actions.get(interactionName);
|
|
335
352
|
if (!command)
|
|
336
353
|
return false;
|
|
337
354
|
if (!command.isDevOnly)
|
|
@@ -394,7 +411,9 @@ export class Command extends command {
|
|
|
394
411
|
? interaction.customId
|
|
395
412
|
: interaction.commandName;
|
|
396
413
|
Logger.debug(`Triggered command-interaction: ${interactionName} for ${interaction.user.id}(${interaction.user.globalName})`);
|
|
397
|
-
const command = this.commands.find((c) => c.name === interactionName) ||
|
|
414
|
+
const command = this.commands.find((c) => c.name === interactionName) ||
|
|
415
|
+
this.actions.get(interactionName) ||
|
|
416
|
+
undefined;
|
|
398
417
|
if (!command) {
|
|
399
418
|
Logger.debug(`❌️ Command with name ${interactionName} not found.`);
|
|
400
419
|
return;
|
|
@@ -406,8 +425,15 @@ export class Command extends command {
|
|
|
406
425
|
}
|
|
407
426
|
return;
|
|
408
427
|
}
|
|
409
|
-
const subCommandName = command.type === "slash" &&
|
|
410
|
-
|
|
428
|
+
const subCommandName = command.type === "slash" &&
|
|
429
|
+
interaction instanceof ChatInputCommandInteraction
|
|
430
|
+
? interaction.options.getSubcommand(false)
|
|
431
|
+
: null;
|
|
432
|
+
const isCommandTypeMatch = command.isSlashCommand() ||
|
|
433
|
+
command.isContextMenuCommand() ||
|
|
434
|
+
command.isButtonAction() ||
|
|
435
|
+
command.isSelectMenuAction() ||
|
|
436
|
+
command.isModalAction();
|
|
411
437
|
if (!isCommandTypeMatch) {
|
|
412
438
|
Logger.debug(`❌️ Command ${interactionName} is not a ${command.type} command`);
|
|
413
439
|
return;
|
|
@@ -450,7 +476,8 @@ export class Command extends command {
|
|
|
450
476
|
else if (command.isButtonAction() && interaction.isButton()) {
|
|
451
477
|
await command.execute(interaction);
|
|
452
478
|
}
|
|
453
|
-
else if (command.isSelectMenuAction() &&
|
|
479
|
+
else if (command.isSelectMenuAction() &&
|
|
480
|
+
interaction.isStringSelectMenu()) {
|
|
454
481
|
await command.execute(interaction);
|
|
455
482
|
}
|
|
456
483
|
else if (command.isModalAction() && interaction.isModalSubmit()) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/core/config.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,OAAO,EAAe,MAAM,IAAI,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAUhF,qBAAa,MAAO,SAAQ,MAAM;IAChC,SAAS,CAAC,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC;IAEnC,OAAO,CAAC,MAAM,CAAC,cAAc;
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/core/config.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,KAAK,OAAO,EAAe,MAAM,IAAI,MAAM,EAAE,MAAM,mBAAmB,CAAC;AAUhF,qBAAa,MAAO,SAAQ,MAAM;IAChC,SAAS,CAAC,MAAM,CAAC,QAAQ,EAAE,OAAO,CAAC;IAEnC,OAAO,CAAC,MAAM,CAAC,cAAc;gBAsEjB,MAAM,EAAE,OAAO;WAUb,GAAG,CAAC,CAAC,SAAS,MAAM,OAAO,EAAE,GAAG,EAAE,CAAC,GAAG,OAAO,CAAC,CAAC,CAAC;WAOhD,aAAa,IAAI,OAAO;CAGvC"}
|
package/dist/core/config.js
CHANGED
|
@@ -29,14 +29,7 @@ export class Config extends config {
|
|
|
29
29
|
throw new EnvConfigError("adminIds must be an array of strings.");
|
|
30
30
|
}
|
|
31
31
|
if (config.options.logging) {
|
|
32
|
-
if (![
|
|
33
|
-
"trace",
|
|
34
|
-
"debug",
|
|
35
|
-
"info",
|
|
36
|
-
"warning",
|
|
37
|
-
"error",
|
|
38
|
-
"fatal",
|
|
39
|
-
].includes(config.options.logging.level)) {
|
|
32
|
+
if (!["trace", "debug", "info", "warning", "error", "fatal"].includes(config.options.logging.level)) {
|
|
40
33
|
throw new EnvConfigError("Logging level must be one of 'trace', 'debug', 'info', 'warning', 'error', 'fatal'.");
|
|
41
34
|
}
|
|
42
35
|
if (typeof config.options.logging.enableFileLogging !== "boolean") {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../../src/core/logger.ts"],"names":[],"mappings":"AAEA,OAAO,EAIL,SAAS,EACT,KAAK,MAAM,IAAI,OAAO,EACvB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAAU,GAAG,IAAI,GAAG,EAAE,KAAK,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAErE,qBAAa,GAAI,SAAQ,GAAG;IAC1B,OAAO,CAAC,MAAM,CAAC,YAAY,CAAkB;IAC7C,gBAAuB,YAAY,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"logger.d.ts","sourceRoot":"","sources":["../../src/core/logger.ts"],"names":[],"mappings":"AAEA,OAAO,EAIL,SAAS,EACT,KAAK,MAAM,IAAI,OAAO,EACvB,MAAM,kBAAkB,CAAC;AAE1B,OAAO,EAAU,GAAG,IAAI,GAAG,EAAE,KAAK,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAErE,qBAAa,GAAI,SAAQ,GAAG;IAC1B,OAAO,CAAC,MAAM,CAAC,YAAY,CAAkB;IAC7C,gBAAuB,YAAY,EAAE,MAAM,CAEzC;IACF,OAAO,CAAC,MAAM,CAAC,MAAM,CAAC,CAAgB;IAEtC,OAAO,CAAC,MAAM,CAAC,uBAAuB;WAOlB,mBAAmB,CAAC,OAAO,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC;IA+DzE,WAAkB,GAAG,IAAI,UAAU,CAAC,OAAO,SAAS,CAAC,CAEpD;WAEa,QAAQ,CAAC,OAAO,EAAE,OAAO,CAAC,IAAI,CAAC,GAAG,IAAI;WAItC,QAAQ,IAAI,OAAO,CAAC,IAAI,CAAC;WAInB,SAAS,IAAI,OAAO,CAAC,IAAI,CAAC;CAG/C;AAED,eAAO,MAAM,MAAM,EAAE,CAAC,GAAG,CAAC,EAAE,MAAM,GAAG,MAAM,EAAE,KAAK,OAOjD,CAAC;AACF,eAAO,MAAM,UAAU,EAAE,OAAkC,CAAC;AAC5D,wBAAgB,mBAAmB,CAAC,QAAQ,EAAE,MAAM,GAAG,MAAM,EAAE,WAK9D"}
|
package/dist/core/logger.js
CHANGED
|
@@ -25,7 +25,7 @@ export class Log extends log {
|
|
|
25
25
|
if (!options) {
|
|
26
26
|
options = Config.get("options")?.logging ?? {
|
|
27
27
|
level: "info",
|
|
28
|
-
enableFileLogging: false
|
|
28
|
+
enableFileLogging: false,
|
|
29
29
|
};
|
|
30
30
|
}
|
|
31
31
|
if (options.enableFileLogging) {
|
|
@@ -46,7 +46,7 @@ export class Log extends log {
|
|
|
46
46
|
maxFiles: 4,
|
|
47
47
|
nonBlocking: true,
|
|
48
48
|
bufferSize: 512 * 1024,
|
|
49
|
-
flushInterval: 100
|
|
49
|
+
flushInterval: 100,
|
|
50
50
|
}),
|
|
51
51
|
}
|
|
52
52
|
: {}),
|
|
@@ -61,18 +61,12 @@ export class Log extends log {
|
|
|
61
61
|
{
|
|
62
62
|
category: "[diskernel]",
|
|
63
63
|
lowestLevel: options.level ?? "info",
|
|
64
|
-
sinks: [
|
|
65
|
-
"console",
|
|
66
|
-
...(options.enableFileLogging ? ["file"] : []),
|
|
67
|
-
],
|
|
64
|
+
sinks: ["console", ...(options.enableFileLogging ? ["file"] : [])],
|
|
68
65
|
},
|
|
69
66
|
{
|
|
70
67
|
category: "main",
|
|
71
68
|
lowestLevel: options.level ?? "info",
|
|
72
|
-
sinks: [
|
|
73
|
-
"console",
|
|
74
|
-
...(options.enableFileLogging ? ["file"] : []),
|
|
75
|
-
],
|
|
69
|
+
sinks: ["console", ...(options.enableFileLogging ? ["file"] : [])],
|
|
76
70
|
},
|
|
77
71
|
],
|
|
78
72
|
});
|
|
@@ -95,9 +89,15 @@ export class Log extends log {
|
|
|
95
89
|
}
|
|
96
90
|
}
|
|
97
91
|
export const Logger = (cat) => {
|
|
98
|
-
return getLogger([
|
|
92
|
+
return getLogger([
|
|
93
|
+
"main",
|
|
94
|
+
...(cat instanceof Array ? cat : cat ? [cat] : []),
|
|
95
|
+
]);
|
|
99
96
|
};
|
|
100
97
|
export const CoreLogger = getLogger("[diskernel]");
|
|
101
98
|
export function getCustomCoreLogger(category) {
|
|
102
|
-
return getLogger([
|
|
99
|
+
return getLogger([
|
|
100
|
+
"[diskernel]",
|
|
101
|
+
...(category instanceof Array ? category : [category]),
|
|
102
|
+
]);
|
|
103
103
|
}
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,GAAG,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAE/C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,EAAE,GAAG,EAAE,MAAM,EAAE,CAAC;AACnE,eAAO,MAAM,SAAS;;;;;;;;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,kBAAkB,CAAC;AACxC,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,KAAK,EAAE,MAAM,iBAAiB,CAAC;AACxC,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,GAAG,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAE/C,OAAO,EAAE,IAAI,EAAE,OAAO,EAAE,KAAK,EAAE,MAAM,EAAE,YAAY,EAAE,GAAG,EAAE,MAAM,EAAE,CAAC;AACnE,eAAO,MAAM,SAAS;;;;;;;;CAQrB,CAAC;AAEF,cAAc,kBAAkB,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -5,5 +5,13 @@ import { Config } from "./core/config.js";
|
|
|
5
5
|
import { ErrorHandler } from "./core/error.js";
|
|
6
6
|
import { Log, Logger } from "./core/logger.js";
|
|
7
7
|
export { Core, Command, Event, Config, ErrorHandler, Log, Logger };
|
|
8
|
-
export const Diskernel = {
|
|
8
|
+
export const Diskernel = {
|
|
9
|
+
Core,
|
|
10
|
+
Command,
|
|
11
|
+
Event,
|
|
12
|
+
Config,
|
|
13
|
+
ErrorHandler,
|
|
14
|
+
Log,
|
|
15
|
+
Logger,
|
|
16
|
+
};
|
|
9
17
|
export * from "./types/index.js";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../src/types/command.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,
|
|
1
|
+
{"version":3,"file":"command.d.ts","sourceRoot":"","sources":["../../src/types/command.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,uBAAuB,EACvB,2BAA2B,EAC3B,oCAAoC,EACpC,sBAAsB,EACtB,iBAAiB,EACjB,2BAA2B,EAC3B,iCAAiC,EACjC,WAAW,EACZ,MAAM,YAAY,CAAC;AAEpB,KAAK,eAAe,GAChB,OAAO,GACP,iBAAiB,GACjB,oBAAoB,GACpB,QAAQ,GACR,YAAY,GACZ,OAAO,CAAC;AAEZ,MAAM,WAAW,YAAY;IAC3B,kBAAkB,CAAC,EAAE,MAAM,CAAC;IAC5B,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,IAAI,CAAC,EAAE,GAAG,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAC5B;AAED,MAAM,WAAW,OAAO;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,EAAE,QAAQ,GAAG,SAAS,GAAG,SAAS,GAAG,MAAM,GAAG,SAAS,GAAG,MAAM,CAAC;IACrE,QAAQ,EAAE,OAAO,CAAC;IAClB,OAAO,CAAC,EAAE;QAAE,IAAI,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MA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B;AAED,8BAAsB,sBAAuB,SAAQ,WAAW,CAAC,oBAAoB,CAAC;;aAKpE,OAAO,CACrB,WAAW,EAAE,oCAAoC,GAChD,OAAO,CAAC,IAAI,CAAC;CACjB;AAED,MAAM,MAAM,QAAQ,CAClB,CAAC,SAAS,OAAO,GAAG,SAAS,EAC7B,CAAC,SAAS,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,SAAS,IAClD,CAAC,SAAS,OAAO,GACjB,aAAa,GACb,CAAC,SAAS,MAAM,GACd,mBAAmB,GACnB,CAAC,SAAS,SAAS,GACjB,sBAAsB,GACtB,KAAK,CAAC;AAEd,MAAM,MAAM,OAAO,CAAC,CAAC,SAAS,QAAQ,GAAG,YAAY,GAAG,OAAO,IAC7D,CAAC,SAAS,QAAQ,GACd,aAAa,GACb,CAAC,SAAS,YAAY,GACpB,iBAAiB,GACjB,CAAC,SAAS,OAAO,GACf,YAAY,GACZ,KAAK,CAAC;AAEhB,MAAM,MAAM,WAAW,GACnB,aAAa,GACb,mBAAmB,GACnB,sBAAsB,CAAC;AAE3B,MAAM,MAAM,UAAU,GAAG,aAAa,GAAG,iBAAiB,GAAG,YAAY,CAAC;AAE1E,MAAM,MAAM,eAAe,GAAG,WAAW,GAAG,UAAU,CAAC"}
|
package/dist/types/command.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/types/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAE/C,MAAM,MAAM,MAAM,GAAG,MAAM,OAAO,iBAAiB,CAAC;AAEpD,MAAM,MAAM,OAAO,GACf;
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/types/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAE/C,MAAM,MAAM,MAAM,GAAG,MAAM,OAAO,iBAAiB,CAAC;AAEpD,MAAM,MAAM,OAAO,GACf;IACE,KAAK,EAAE,OAAO,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,GAAG,OAAO,CAAC;IAClE,iBAAiB,EAAE,KAAK,CAAC;CAC1B,GACD;IACE,KAAK,EAAE,OAAO,GAAG,OAAO,GAAG,MAAM,GAAG,SAAS,GAAG,OAAO,GAAG,OAAO,CAAC;IAClE,iBAAiB,EAAE,IAAI,CAAC;IACxB,WAAW,EAAE,MAAM,CAAC;CACrB,CAAC;AAEN,MAAM,WAAW,cAAc;IAC7B,qBAAqB,EAAE,OAAO,CAAC;IAC/B,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B,mBAAmB,EAAE,OAAO,CAAC;IAC7B,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,mBAAmB,EAAE,OAAO,CAAC;IAC7B,yBAAyB,EAAE,OAAO,CAAC;CACpC;AAED,MAAM,WAAW,OAAO;IACtB,QAAQ,CAAC,EAAE,MAAM,EAAE,CAAC;IACpB,OAAO,EAAE,OAAO,CAAC;IACjB,OAAO,EAAE,cAAc,CAAC;CACzB;AAED,MAAM,WAAW,OAAO;IACtB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,EAAE,CAAC;IAClB,OAAO,EAAE,OAAO,CAAC;CAClB"}
|