DiscordLua
discorddiscord
v1.2.4
Install

CLI

CLI
On this page

dislua runs Lua scripts, scaffolds a starter bot, reports versions, and updates the installed package.

Installation

Install with DiscordLua-Setup.exe (GUI launcher 1.1.0), then open a new terminal so dislua is on PATH. Confirm with dislua version.

Commands

Full syntax, arguments, output, and errors live on the commands page.

Configuration

Environment variables the CLI and runtime read. See also the configuration page.

VariablePurpose
DISCORD_TOKENBot token for client:login and shard children.
MYLUA_MODULE_PATHOverride on-disk module root. Disk modules win over the embedded copies.
MYLUA_LOGLog level (debug, info, and other native levels).
DISCORDLUA_UPDATE_APIOverride the version manifest URL.
DISCORDLUA_SHARD_ID / DISCORDLUA_SHARD_COUNTIdentify shard fields for child processes.

Updating

CLI 1.1.0 requires launcher 1.1.0. dislua update downloads DiscordLua-Setup.exe from the version API and opens the launcher. You do not need to open the docs site. Older command-line Setup installs are blocked until that update finishes.

shell
dislua check-update
dislua update

The launcher can also install, reinstall, or uninstall with determinate progress. Direct download: DiscordLua-Setup.exe.

Troubleshooting

  • dislua doctor prints EXE, install, and module paths.
  • If require("discord") fails, set MYLUA_MODULE_PATH or re-run setup so modules are extracted next to the install root.
  • Updates require HTTPS (or localhost) download URLs.
  • Close running bots before dislua update replaces the EXE.
Search Ctrl K Navigate Open Esc