Guides
Install Shell Completions
Generate and install tab completion for bash, zsh, or fish, so uxd completes your project names, verbs, and existing workspace slugs.
uxd completions <shell> prints a completion script to stdout. You install it
by sourcing that output.
Install
# ~/.bashrc
eval "$(uxd completions bash)"
# ~/.zshrc
eval "$(uxd completions zsh)"
# ~/.config/fish/config.fish
uxd completions fish | source
Open a new shell, or re-source the file, and completion is live.
eval runs uxd on every shell start. If startup time matters, write the
script to disk once instead:uxd completions zsh > ~/.zsh/completions/_uxd
What gets completed
| Position | Completes |
|---|---|
| First argument | Top-level verbs and your project names |
| After a project | Workspace verbs and the slugs that already exist |
| Anywhere else | Workspace verbs |
The project list is baked into the script when it is generated, which is why a
new project in ~/.uxd/ needs a regenerate. Workspace slugs are looked up live
— the script calls uxd <project> list --json while you type.
The top-level verbs it offers are setup, projects, doctor, config,
completions, help, version; the workspace verbs are list, clean,
checkout, code, run, exec, shell, sync, diff, info, rm.
Errors
Only three shells are supported. Anything else is a usage error:
uxd completions ksh
error(E_USAGE): unsupported shell 'ksh'
hint: one of: bash, zsh, fish
Omitting the shell fails the same way:
error(E_USAGE): completions requires a shell
hint: one of: bash, zsh, fish
Both exit 2. See Exit codes.