Skip to content

nonlooped/forgeloop

Repository files navigation

ForgeLoop

A maintenance-first Discord bot scaffolder for discord.js.
Create a bot fast, grow it without chaos, and keep the project clean later with built-in generators and health checks.

npm version npm downloads TypeScript discord.js License

ForgeLoop is a Discord bot starter CLI built for people who want more than a one-time template.
It helps you:

  • scaffold a new Discord bot project
  • add commands and events later
  • keep the structure consistent
  • avoid starter-template rot
  • scale from simple bots to larger projects

If you like discord.js but hate repeating setup, reorganizing folders halfway through, or manually wiring everything every time, ForgeLoop is for you.


Why ForgeLoop?

Most bot starters help you get started.

ForgeLoop helps you keep going.

Instead of dumping files and disappearing, ForgeLoop gives you a cleaner path for long-term maintenance:

  • multiple starter shapes for different project sizes
  • follow-up generators for commands and events
  • project checks to catch drift and missing structure
  • config-driven setup so the project stays understandable
  • TypeScript and JavaScript support

What you get

You can choose a setup that matches how big or structured you want the bot to be.

Starter styles

  • Basic - quick prototypes and tiny bots
  • Modular - clean command/event separation for most real projects
  • Advanced - clearer runtime structure for bigger bots

Project choices

ForgeLoop can scaffold with options like:

  • TypeScript or JavaScript
  • npm, pnpm, or yarn
  • SQLite or PostgreSQL
  • Prisma
  • ESLint + Prettier, Biome, or no tooling
  • optional Git, Docker, CI, and dependency install

Quick start

Create a new bot:

npm create forgeloop@latest my-bot

Other supported flows:

pnpm create forgeloop my-bot
yarn create forgeloop my-bot
npx create-forgeloop@latest my-bot

Run the interactive wizard:

npm create forgeloop@latest

The published package name is create-forgeloop, but create-style commands use the suffix forgeloop.


Keep using it after setup

ForgeLoop is not just a starter.

Inside supported ForgeLoop projects, you can keep using it to grow the bot over time:

  • add new application commands and interaction handlers
  • add a new event
  • inspect the current project setup
  • run a doctor check to catch structural issues

That means less copy-pasting, less forgetting boilerplate, and allows you to focus on the bot code instead of the wiring.


Example use cases

  • Starting a new Discord bot without hand-rolling the same structure again
  • Creating a cleaner base for a production discord.js bot
  • Adding commands/events later without manually wiring everything
  • Keeping a team project consistent across updates

Command examples

Create a TypeScript modular bot:

npx create-forgeloop@latest my-bot --language ts --preset modular

Add a command to an existing supported project:

pnpm forgeloop add command status --description "Show current bot status"

Add a context menu command:

pnpm forgeloop add context-menu inspect-user --type user

Add an event handler:

pnpm forgeloop add event clientReady --once

Run grouped diagnostics with CI-friendly output:

pnpm forgeloop doctor --strict --checks config,structure,env,deps,discord

Run a structural health check:

npx create-forgeloop@latest doctor --dir ./my-bot

Agent Skill

ForgeLoop includes a project skill at .agents/skills/forgeloop so AI coding agents can apply ForgeLoop-specific workflows.

Install from this repository:

npx skills add nonlooped/forgeloop --skill forgeloop

Preview skills detected in this repository:

npx skills add nonlooped/forgeloop --list

Docs

Full docs, setup details, and command reference:

Clone the repo, install with pnpm (see packageManager in root package.json), then from the repository root:

pnpm install
pnpm run docs:dev

Build docs locally:

pnpm run docs:build

Preview the built site:

pnpm run docs:serve

Package


License

MIT LICENSE

About

Discord bot scaffolder and CLI for discord.js with TypeScript/JavaScript starters, generators, and health checks.

Topics

Resources

License

Stars

Watchers

Forks

Contributors