This repository contains a TypeScript-based Discord bot. Follow the steps below to set up and run the bot.
-
Install Bun
Bun is a fast JavaScript runtime. Follow the instructions on the official website to install it. -
Install MongoDB Community Edition
Download and install MongoDB Community Edition from MongoDB's official website.
-
Clone the repository to your local machine:
git clone <repository-url> cd TypeScript-Discord-Base
-
Install dependencies using Bun:
bun i
-
Configure environment variables:
- Create a
.envfile by renaming.env.tempto.env:mv .env.temp .env
- Open the
.envfile and fill in the required values (e.g., Discord bot token, MongoDB connection string, etc.).
- Create a
-
Start the bot:
bun .
- Ensure MongoDB is running locally or accessible via the connection string provided in the
.envfile. - If you encounter any issues, check the logs for debugging information.
Enjoy using the bot!