Files
website/docs/cli/clear.md
Jacob Nguyen c9d8ef511a clear
2024-01-25 21:31:56 -06:00

1.1 KiB

Usage: sern commands clear [options]

Clear and reset commands-data-remote.json and the api

Options:
  -y, --yes         Say yes to all prompts
  -e, --env [path]  Supply a path to a .env
  -h, --help        display help for command

Implicits

  • Automatically reads a .env in the working directory. For seamless integration, your .env file should look like this:
DISCORD_TOKEN=<YOUR_TOKEN>
APPLICATION_ID=<YOUR_APPLICATION_ID>
NODE_ENV=<development|production>
  • Calls the discord API with the PUT route with an EMPTY array, essentially setting all registered commands to nothing.

  • Optionally override an .env path as a command line argument as well. CLI arguments take precedence. If you do not know how to obtain either of these credentials, click here

  • Automatically confirm with the -y flag.

Features

  • Clears all application data and sern-commands-data.json