Skip to content

Add shell completions by shtab#121

Merged
dbarnett merged 1 commit into
google:masterfrom
Freed-Wu:master
Sep 29, 2022
Merged

Add shell completions by shtab#121
dbarnett merged 1 commit into
google:masterfrom
Freed-Wu:master

Conversation

@Freed-Wu

Copy link
Copy Markdown
Contributor
vimdoc --print-completion bash | sudo tee /usr/share/bash-completion/completions/vimdoc
vimdoc --print-completion tcsh | sudo tee /etc/profile.d/vimdoc.completion.csh
vimdoc --print-completion zsh | sudo tee /usr/share/zsh/site-functions/_vimdoc
❯ vimdoc -<TAB>
option
--help               show this help message and exit
-h                   show this help message and exit
--print-completion   print shell completion script
--version            show program's version number and exit
❯ vimdoc <TAB>
plugin
scripts/  tests/    vimdoc/
    extras_require={'completion': ['shtab']},

vimdoc --print-completion bash | sudo tee /usr/share/bash-completion/completions/vimdoc
vimdoc --print-completion tcsh | sudo tee /etc/profile.d/vimdoc.completion.csh
vimdoc --print-completion zsh | sudo tee /usr/share/zsh/site-functions/_vimdoc
@dbarnett dbarnett merged commit 823e3bb into google:master Sep 29, 2022
@dbarnett

Copy link
Copy Markdown
Contributor

@Freed-Wu do you know if it gives self-contained usage details for how to set up the completions that you can access from vimdoc --help or something? Otherwise we might want to add a note to README or something.

@Freed-Wu

Copy link
Copy Markdown
Contributor Author

how to set up the completions

The setup method can be seen from https://docs.iterative.ai/shtab/use/. Maybe a note is useful.

dbarnett added a commit that referenced this pull request Oct 31, 2022
Changes since 0.7.0:
* Avoid creating junk "plugin[flags]" tag (#117)
* Add shell completions by shtab (#121)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants