Skip to content

Commit 53a92ab

Browse files
committed
README: Add completion documentation
Adds documentation on generating bash and zsh completions.
1 parent 6f2cac7 commit 53a92ab

File tree

1 file changed

+19
-0
lines changed

1 file changed

+19
-0
lines changed

README.md

Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -93,6 +93,25 @@ Enter default GitLab host (default: https://gitlab.com):
9393
Enter default GitLab user: zaq
9494
Enter default GitLab token:
9595
```
96+
# Completions
97+
98+
`lab` provides completions for bash and zsh.
99+
100+
### Bash
101+
102+
`lab completion bash` will generate a bash completion script. Save this script and source it in your `.bashrc`:
103+
104+
```bash
105+
source "/path/to/lab-completions.bash"
106+
```
107+
108+
### Zsh
109+
110+
`lab completion zsh` will generate a zsh completion script. zsh completions are denoted with the syntax `_command-name`, so save the output of `lab completion` to a file name `_lab`. Place the file in your `$FPATH`, or create an new directory and add it to your `$FPATH`.
111+
112+
```zsh
113+
fpath=(/path/to/script_directory $fpath)
114+
```
96115

97116
# Aliasing
98117

0 commit comments

Comments
 (0)