Open blueyed opened 7 years ago
pytest already supports the argcomplete protocol
Thanks!
I came across that before, but for zsh
it requires bashcompinit
(a wrapper to enable bash completions), and the completion itself is slow (it seems to be not cached at all), and does not support completing (c)tags after -k
, which was my initial motivation to create a completion script for pytest, since this easily allows to complete test functions.
i see what you mean, i wonder if that can be done in a multi shell fashion
How about shtab? It is faster than argcomplete and pyzshcomplete. And it supports more shells.
Seems useful if we had at least basic shell completion for the built-in pytest arguments.
Should we include/ship shell completion with pytest, e.g. in a
contrib
folder?I have something for Zsh: https://github.com/zsh-users/zsh-completions/pull/454/files.
Added to my dotfiles: https://github.com/blueyed/oh-my-zsh/commit/fd89b191b808adc4c913f667109d5c9702bba713 (2020-03-01)