Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

slash-up

Snazzah845MIT1.4.2TypeScript support: included

CLI for viewing and syncing Discord commands with slash-create

api, discord, discordapp, slash-create, slash-command, slash-commands, discord-interactions, cli

readme

NPM version NPM downloads ESLint status DeepScan grade discord chat

CLI to view Discord commands and sync commands with slash-create.

slash-up <command>

Commands
  slash-up list                    View the list of commands on Discord
  slash-up view [command]          View a command on Discord
  slash-up local                   View the list of local commands
  slash-up sync                    Sync local commands to Discord
  slash-up init [template] [dest]  Clone a slash-create template into a new directory
  slash-up config [dir]            Create a config file in the specified directory

Other Options
  -h, --help     Show usage information & exit                                             [boolean]
  -v, --version  Show version number & exit                                                [boolean]

Config

Config files are taken from slash-up.config.js file or the file set from --config flag. You can create a config template file from npx slash-up config. | Property | Type | Description | |----------|------|-------------| | token | string | The token of the Discord bot | | applicationId | string | The application ID of the Discord bot | | commandPath | string | The path to the local commands directory | | globalToGuild | string? | The guild ID to set all global commands to when syncing, best for development environments | | beforeSync | 'block'/'confirm'? | What to do before syncing, 'confirm' prompts you before syncing | | env | object? | An object with keys as environment names and values as configs. You can use --env (-e) to use an environment's config |

changelog

Changelog

All notable changes to this project will be documented in this file.

The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

Unreleased

1.4.2 - 2023-11-06

Fixed:

  • Fixed issue when listing local commands
  • Fixed local commands not showing some attributes

    1.4.1 - 2023-11-06

    Fixed:

  • Fixed a bug in the previous release creating errors when syncing

    [1.4.0] - 2023-11-05

    Added:

  • Added future v6 compatibility
  • Added .cjs, .mjs, .mts, and .cts extensions to be automatically registered.

    1.3.0 - 2023-03-09

    Changed:

  • slash-up can now be ran in ESM projects without error, using @esbuild-kit/cjs-loader instead of ts-node for module loading

    1.2.1 - 2022-10-12

    Fixed:

  • Call process.exit after syncing
  • Print error stacktrace on command require errors

    1.2.0 - 2022-06-14

    Changed:

  • Updated slash-create to 5.6.1

    Added:

  • slash-up view now shows DM permissions, default member permissions, and localizations. Default permission only shows if the value is false.

    1.1.2 - 2022-05-06

    Changed:

  • Updated slash-create to 5.5.3

    Fixed:

  • Only transpile .ts files (should be faster)
  • No longer logs invalid command errors

    1.1.1 - 2022-04-29

    Changed:

  • Updated slash-create to 5.5.2

    Fixed:

  • Register errors now show the file's path

    1.1.0 - 2022-04-03

    Added:

  • slash-up will now find a .env file based on the env given in the CLI. For example, doing slash-up list -e dev will look for a dev.env file before finding .env.

    1.0.11 - 2022-01-23

    Changed:

  • Register command failures will now be logged with the debug flag is on

    1.0.10 - 2022-01-06

    Fixed:

  • beforeSync and commandPath flags not being used in config
  • Requiring TypeScript files now uses ts-node. (This is a bit slow, it might be best to compile and set that as the path)

    1.0.9 - 2022-01-02

    Fixed:

  • Fix typescript importing again
  • Fix some missing options in slash-up local

    1.0.8 - 2021-12-31

    Fixed:

  • Fix loading local commands in non-typescript environments

    1.0.7 - 2021-12-29

    Fixed:

  • Fixed dependencies for non-typescript environments

    1.0.6 - 2021-12-26

    Fixed:

  • Fix global to guild syncing to global aswell in slash-up sync

    1.0.5 - 2021-12-21

    Fixed:

  • Fixed a typo in slash-up config

    1.0.4 - 2021-12-21

    Fixed:

  • Fixed an error when a template is only provided in slash-up init

    1.0.3 - 2021-12-21

    Fixed:

  • Fixed comma and tabs in slash-up config

    1.0.2 - 2021-12-21

    Added:

  • slash-up init now installs packages and renames .env.example after cloning

    Fixed:

  • Fixed creating a config file from slash-up config

    1.0.1 - 2021-12-20

    Fixed:

  • Fixed TS requiring config.

    1.0.0 - 2021-12-20

  • Initial release.