1
0
dotfiles/.config/zsh/completion/external.zsh

18 lines
567 B
Bash
Raw Permalink Normal View History

#!/bin/zsh
2024-02-18 02:32:08 +03:00
typeset -A ZSHU_COMP_EXTERNAL
2024-02-18 02:32:08 +03:00
for i ( kubectl podman skopeo docker ) ; do
ZSHU_COMP_EXTERNAL[$i]="command $i completion zsh"
2022-07-19 02:41:45 +03:00
done ; unset i
2024-02-18 15:10:19 +03:00
2024-02-18 02:32:08 +03:00
## example of "automatic" shell completion generation
2024-02-18 15:10:19 +03:00
# ZSHU_COMP_EXTERNAL[yq]='command yq shell-completion zsh'
2024-02-18 02:32:08 +03:00
__z_comp_ext__yq() { command yq shell-completion zsh ; }
## example of more complex shell completion generation
# __z_comp__shifty_nifty() { command shifty-nifty completion zsh | sed -E 's/shifty_nifty/shifty-nifty/g' ; }
# ZSHU_COMP_EXTERNAL[shifty-nifty]='__z_comp__shifty_nifty'
z-comp-auto