Skip to content

Shell completion

git-spice supports completion for Bash, Zsh, and Fish. To set up completion, follow the instructions below.

Add the following line to your .bashrc or .bash_profile:

eval "$(gs shell completion bash)"

Add the following line to your .zshrc or .zprofile:

eval "$(gs shell completion zsh)"

Add the following line to your config.fish:

eval "$(gs shell completion fish)"

Then restart the shell or create a new shell session.

Debugging shell completion

If shell completion misbehaves and you want to file a bug report, first retry the completion with COMP_DEBUG=1 set.

$ export COMP_DEBUG=1$ gs branch onto # <TAB>

This will print debugging information about the completion process. Include this output in your bug report.