Skip to content

Commit b962122

Browse files
navarroaxelbl-ue
andauthored
gh-completion: add page (#5134)
Co-authored-by: bl-ue <54780737+bl-ue@users.noreply.github.com>
1 parent b92f1b9 commit b962122

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

pages/common/gh-completion.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# gh completion
2+
3+
> Generate shell completion scripts for GitHub CLI commands.
4+
> More information: <https://cli.github.com/manual/gh_completion>.
5+
6+
- Display the subcommand help:
7+
8+
`gh completion`
9+
10+
- Print a completion script:
11+
12+
`gh completion --shell {{bash|zsh|fish|powershell}}`
13+
14+
- Append the `gh` completion script to `~/.bashrc`:
15+
16+
`gh completion --shell {{bash}} >> {{~/.bashrc}}`
17+
18+
- Append the `gh` completion script to `~/.zshrc`:
19+
20+
`gh completion --shell {{zsh}} >> {{~/.zshrc}}`

0 commit comments

Comments
 (0)