Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/brunos3d/discord-bot-typescript-boilerplate
🤖 NODE.TS - Start your next discord bot project in seconds.
https://github.com/brunos3d/discord-bot-typescript-boilerplate
boilerplate bot clone container discord discord-bot discord-js discordjs docker eslint getting-started image quickstart starter-project starter-template template template-project template-repository typescript
Last synced: 4 days ago
JSON representation
🤖 NODE.TS - Start your next discord bot project in seconds.
- Host: GitHub
- URL: https://github.com/brunos3d/discord-bot-typescript-boilerplate
- Owner: brunos3d
- License: mit
- Created: 2020-08-01T10:29:53.000Z (over 4 years ago)
- Default Branch: main
- Last Pushed: 2022-02-07T18:39:57.000Z (almost 3 years ago)
- Last Synced: 2024-01-17T00:16:11.243Z (10 months ago)
- Topics: boilerplate, bot, clone, container, discord, discord-bot, discord-js, discordjs, docker, eslint, getting-started, image, quickstart, starter-project, starter-template, template, template-project, template-repository, typescript
- Language: TypeScript
- Homepage:
- Size: 151 KB
- Stars: 15
- Watchers: 2
- Forks: 1
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Security: SECURITY.md
Awesome Lists containing this project
README
# discord-bot-typescript-boilerplate
🤖 NODE.TS - Start your next discord bot project in seconds.
## Installation
Clone project
```
git clone [email protected]:BrunoS3D/discord-bot-typescript-boilerplate.git your-app-name
cd your-app-name
```Install dependencies
```sh
yarn install # or just yarn
```Create environment variable files `.env` and `.env.dev` based on [.env.example](./.env.example) on project root folder
```bash
# linux / macOS
cp .env.example .env
cp .env.example .env.dev
``````bash
# windows
copy .env.example .env
copy .env.example .env.dev
```## Running on development environment
> âš Remember to follow the [Installation](#Installation) steps before proceeding
Running the bot
```sh
yarn dev # or cross-env NODE_ENV=development env-cmd -f .env.dev tsnd --transpile-only --respawn --no-notify --ignore-watch node_modules ./src/index.ts
```> âš Note that the loaded environment variables file is `.env.dev`
## Running on production environment
### With Docker
> âš Remember to follow the [Installation](#Installation) steps before proceeding
```bash
docker build -t your-app-name .
docker run -it --rm -e DISCORD_TOKEN="YOUR TOKEN HERE" --name your-app-name your-app-name
```### With Docker Compose
> âš Remember to follow the [Installation](#Installation) steps before proceeding
```bash
docker compose up -d
```> âš Note that the loaded environment variables file is `.env`
### Without Docker Compose
> âš Remember to follow the [Installation](#Installation) steps before proceeding
Directly
```bash
yarn deploy
```> âš Note that the loaded environment variables file is `.env`
Manually
```bash
yarn build
```Startup bot
```bash
yarn start # or cross-env NODE_ENV=production env-cmd -f .env node ./dist/index.js
```> âš Note that the loaded environment variables file is `.env`