Skip to content

Commit 0f2023b

Browse files
committed
docs(readme): add Shell Completion section
Documents how to install <TAB> completion for bash, zsh, fish, and PowerShell. Includes a one-liner for each shell plus a reminder to re-run the completion command after upgrading ado to pick up new subcommands and options.
1 parent 178fec5 commit 0f2023b

1 file changed

Lines changed: 25 additions & 0 deletions

File tree

README.md

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -88,6 +88,31 @@ ado workitems create MyProject --type Bug --title "Fix login page"
8888
ado prs create MyProject MyRepo --title "Add feature" --source dev --target main
8989
```
9090

91+
## Shell Completion
92+
93+
`<TAB>` works out of the box once you source the generated script:
94+
95+
```bash
96+
# bash (add to ~/.bashrc)
97+
eval "$(ado completion bash)"
98+
99+
# zsh (add to ~/.zshrc; also works as a one-liner)
100+
ado completion zsh > "${fpath[1]}/_ado"
101+
102+
# fish (add to ~/.config/fish/config.fish)
103+
ado completion fish | source
104+
105+
# PowerShell (add to $PROFILE)
106+
ado completion powershell | Out-String | Invoke-Expression
107+
```
108+
109+
After installing, pressing `<TAB>` after `ado ` shows every top-level
110+
subcommand; after `ado prs ` shows `abandon`, `comments`, `complete`,
111+
`create`, `diff`, `list`, `show`; and so on at every nesting level.
112+
113+
Re-run the completion command after upgrading `ado` to pick up new
114+
subcommands and options.
115+
91116
---
92117

93118
## For LLM Agents (pi, Claude Code, Copilot, Cursor, Codex)

0 commit comments

Comments
 (0)