Skip to content

Completion Commands

Enable tab completion for bash, zsh, or fish shells.

Global options available on completion commands: --json, --no-color.

ShellConfig File
bash~/.bashrc
zsh~/.zshrc
fish~/.config/fish/config.fish

Install shell completions for your current shell.

Terminal window
bb completion install [options]
OptionDescription
--jsonOutput as JSON

The installer auto-detects your shell and adds the necessary configuration.

After installing, restart your shell or source your config:

Terminal window
# Bash
source ~/.bashrc
# Zsh
source ~/.zshrc
# Fish
source ~/.config/fish/config.fish
Terminal window
# Install completions
bb completion install
# Install with JSON output
bb completion install --json
# Test it works
bb <Tab> # Shows: auth, repo, pr, config, completion
bb repo <Tab> # Shows: clone, create, list, view, delete

Remove shell completions.

Terminal window
bb completion uninstall [options]
OptionDescription
--jsonOutput as JSON
Terminal window
# Remove completions
bb completion uninstall
# Remove completions with JSON output
bb completion uninstall --json

Tab completion works for:

  • Commands: auth, repo, pr, config, completion
  • Subcommands: login, clone, create, list, etc.
  • Options: --json, --no-color, --workspace, --repo, --help

-w is reserved as the global shorthand for --workspace.

Terminal window
$ bb pr<Tab>
pr
$ bb pr <Tab>
activity approve checks checkout comments create decline
diff edit list merge ready reviewers view
$ bb pr create --<Tab>
--body --close-source-branch --destination
--draft --help --repo
--source --title --workspace