Skip to content

Add 'site-functions' to $fpath

Add /usr/share/zsh/site-functions into the standard $fpath to allow several package completions to be picked up by zsh.

Reason to add this to debian zsh instead of fixing the other packages:

  • zsh autoconf uses 'site-functions' by default
  • most other distributions configure it or rely on the default

Naturally a lot of applications install their completions into /usr/share/zsh/site-functions.

Closes: #535851

Tested in chroot with 'kmod' completion of lsmod

With site-functions

# lsmod -<TAB>
Completing option
--help     -h  -- show this help                                                                                                  
--syslog   -s  -- print to syslog, not stderr                                                                                     
--verbose  -v  -- enables more messages                                                                                           
--version  -V  -- show version

completion from /usr/share/zsh/site-functions/_lsmod

Without, on current stable

$ lsmod -<TAB>
--help     -h  -- display usage information                                                                                        
--version  -V  -- display version information

completion from /usr/share/zsh/functions/Completion/Linux/_modutils

Merge request reports

Loading