UNPKG

discord-bot-cli

Version:

An easy way to build a command-based discord bot with discord.js.

30 lines (29 loc) 830 B
#!/usr/bin/env node "use strict"; var __importDefault = (this && this.__importDefault) || function (mod) { return (mod && mod.__esModule) ? mod : { "default": mod }; }; Object.defineProperty(exports, "__esModule", { value: true }); const helpString = ` Usage dbc <command> [options] [--help] Commands cmd, c Create a new command file loc, l Create a new localization file `; const new_command_1 = __importDefault(require("./new-command")); const localization_1 = __importDefault(require("./localization")); const [, , cmd] = process.argv; switch (cmd) { case "cmd": case "c": new_command_1.default(); break; case "loc": case "l": localization_1.default(); break; default: console.log(helpString); process.exit(2); }