blob: a88cc5445e26ba6f50a4b2ffc3deb798c15e619a [file] [log] [blame]
pineafan63fc5e22022-08-04 22:04:10 +01001import runServer from "./api/index.js";
pineafan63fc5e22022-08-04 22:04:10 +01002import client from "./utils/client.js";
PineaFan64486c42022-12-28 09:21:04 +00003import config from "./config/main.json" assert { type: "json" };
4import register from "./utils/commandRegistration/register.js";
PineaFan538d3752023-01-12 21:48:23 +00005import { record as recordPerformance } from "./utils/performanceTesting/record.js";
Skyler Turner66ac7942022-02-24 01:59:22 +00006
pineafane625d782022-05-09 18:04:32 +01007client.on("ready", () => {
PineaFan64486c42022-12-28 09:21:04 +00008 console.log(`Logged in as ${client.user!.tag}!`);
9 register();
pineafane625d782022-05-09 18:04:32 +010010 runServer(client);
11});
PineaFan0d06edc2023-01-17 22:10:31 +000012process.on("unhandledRejection", (err) => { console.error(err) });
13process.on("uncaughtException", (err) => { console.error(err) });
pineafan1dc15722022-03-14 21:27:34 +000014
PineaFan0d06edc2023-01-17 22:10:31 +000015await client.login(config.enableDevelopment ? config.developmentToken : config.token)
PineaFan538d3752023-01-12 21:48:23 +000016
TheCodedProffc420b72023-01-24 17:14:38 -050017await recordPerformance();
18
19import { getCommandMentionByName} from "./utils/getCommandMentionByName.js";
20console.log(await getCommandMentionByName("nucleus/premium"))