A cross-platform command-line interface for installing, updating, and managing BetterDiscord.
- π Easy installation and uninstallation of BetterDiscord
- π Support for multiple Discord channels (Stable, PTB, Canary)
- π₯οΈ Cross-platform support (Windows, macOS, Linux)
- π¦ Available via npm for easy distribution
- β‘ Fast and lightweight Go binary
npm install -g @betterdiscord/cligo install github.com/betterdiscord/cli@latestwinget install betterdiscord.clibrew install betterdiscord/tap/bdcliDownload the latest release for your platform from the releases page.
Install BetterDiscord to a specific Discord channel:
bdcli install --channel stable # Install to Discord Stable
bdcli install --channel ptb # Install to Discord PTB
bdcli install --channel canary # Install to Discord CanaryInstall BetterDiscord by providing a Discord install path:
bdcli install --path /path/to/DiscordUninstall BetterDiscord from a specific Discord channel:
bdcli uninstall --channel stable # Uninstall from Discord Stable
bdcli uninstall --channel ptb # Uninstall from Discord PTB
bdcli uninstall --channel canary # Uninstall from Discord CanaryUninstall BetterDiscord by providing a Discord install path:
bdcli uninstall --path /path/to/Discordbdcli versionbdcli completion bash
bdcli completion zsh
bdcli completion fishbdcli --help
bdcli [command] --helpA cross-platform CLI for installing, updating, and managing BetterDiscord.
Usage:
bdcli [flags]
bdcli [command]
Available Commands:
completion Generate shell completions
help Help about any command
install Installs BetterDiscord to your Discord
uninstall Uninstalls BetterDiscord from your Discord
version Print the version number
Flags:
-h, --help help for bdcli
Use "bdcli [command] --help" for more information about a command.
- Windows (x64, ARM64, x86)
- macOS (x64, ARM64/M1/M2)
- Linux (x64, ARM64, ARM)
- Go 1.26 or higher
- Task (optional, for task automation)
- GoReleaser (for releases)
Clone the repository and install dependencies:
git clone https://github.com/BetterDiscord/cli.git
cd cli
task setup # Or: go mod downloadRun task --list-all to see all available tasks:
# Development
task run # Run the CLI (pass args with: task run -- install stable)
# Building
task build # Build for current platform
task build:all # Build for all platforms (GoReleaser)
# Testing
task test # Run tests
task test:verbose # Run tests with verbose output
task coverage # Run tests with coverage summary
task coverage:html # Generate HTML coverage report
# Code Quality
task fmt # Format Go files
task vet # Run go vet
task lint # Run golangci-lint
task check # Run fix, fmt, vet, lint, test
# Release
task release:snapshot # Test release build
task release # Create release (requires tag)
# Cleaning
task clean # Remove build and debug artifacts# Run directly
go run main.go install stable
# Or use Task
task run -- install stable# Build for current platform
task build
# Build for all platforms
task build:all
# Output will be in ./dist/# Run all tests
task test
# Run with coverage
task coverage-
Create and push a new tag:
git tag -a v0.2.0 -m "Release v0.2.0" git push origin v0.2.0 -
GitHub Actions will automatically build and create a draft release
-
Edit the release notes and publish
-
Publish to npm:
npm publish
.
βββ cmd/ # Cobra commands
β βββ install.go # Install command
β βββ uninstall.go # Uninstall command
β βββ version.go # Version command
β βββ root.go # Root command
βββ internal/ # Internal packages
β βββ betterdiscord/ # BetterDiscord installation logic
β βββ discord/ # Discord path resolution and injection
β βββ models/ # Data models
β βββ utils/ # Utility functions
βββ main.go # Entry point
βββ Taskfile.yml # Task automation
βββ .goreleaser.yaml # Release configurationContributions are welcome! Please feel free to submit a Pull Request.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature) - Commit your changes (
git commit -m 'feat: add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
This project is licensed under the Apache License 2.0 - see the LICENSE file for details.
Built with:
- Cobra - CLI framework
- GoReleaser - Release automation
- Task - Task runner
Made with β€οΈ by the BetterDiscord Team