Skip to content

completions

Generate shell completion scripts for tab-completion of rung commands and options.

Usage

Terminal window
rung completions <shell>

Aliases

  • rung comp — shorthand for rung completions

Supported Shells

ShellValue
Bashbash
Zshzsh
Fishfish
PowerShellpowershell
Elvishelvish

Installation

Bash

Terminal window
# Add to ~/.bashrc or ~/.bash_profile
rung completions bash >> ~/.bash_completion
source ~/.bash_completion

Or for system-wide installation:

Terminal window
rung completions bash | sudo tee /etc/bash_completion.d/rung > /dev/null

Zsh

Terminal window
# Create completions directory if needed
mkdir -p ~/.zsh/completions
# Generate completions
rung completions zsh > ~/.zsh/completions/_rung
# Add to ~/.zshrc (if not already present)
echo 'fpath=(~/.zsh/completions $fpath)' >> ~/.zshrc
echo 'autoload -Uz compinit && compinit' >> ~/.zshrc

Fish

Terminal window
rung completions fish > ~/.config/fish/completions/rung.fish

PowerShell

Terminal window
# Add to your PowerShell profile
rung completions powershell >> $PROFILE

Elvish

Terminal window
rung completions elvish > ~/.elvish/lib/rung.elv
# Then add `use rung` to ~/.elvish/rc.elv

Example

After installing completions, you can tab-complete:

Terminal window
$ rung <TAB>
create doctor init log merge move nxt prv
status submit sync undo update completions
$ rung sync --<TAB>
--abort --base --continue --dry-run --json --no-push --quiet
$ rung merge --method <TAB>
merge rebase squash

Notes

  • Completions are generated from the CLI definition, so they’re always up-to-date
  • You may need to restart your shell or source your config after installation
  • Some shells require additional setup for completions to work
  • doctor — Verify rung is working correctly