mirror of
git://git.code.sf.net/p/zsh/code
synced 2024-11-20 05:53:52 +01:00
moved to Completion/Unix/Type/_perl_basepods
This commit is contained in:
parent
852ca68350
commit
a201dea6e7
@ -1,32 +0,0 @@
|
||||
#autoload
|
||||
#
|
||||
# _perl_basepods - zsh completion function
|
||||
#
|
||||
# Adam Spiers <adam@spiers.net>
|
||||
#
|
||||
# Calculate all installed Perl base pods (perlfunc, perlfaq etc.).
|
||||
# The result is cached for future use.
|
||||
#
|
||||
|
||||
if [[ ${+_perl_basepods} -eq 0 ]]; then
|
||||
typeset -agU _perl_basepods
|
||||
|
||||
if (( ${+commands[basepods]} )); then
|
||||
_perl_basepods=( ${$(basepods):t:r} )
|
||||
else
|
||||
local podpath
|
||||
|
||||
podpath=$(perl -MConfig -e 'print "$Config{installprivlib}/pod"')
|
||||
|
||||
if [[ ! -e $podpath/perl.pod ]]; then
|
||||
echo "Couldn't find perl.pod from Config.pm; giving up."
|
||||
return 1
|
||||
else
|
||||
_perl_basepods=( ${podpath}/*.pod(:r:t) )
|
||||
fi
|
||||
fi
|
||||
fi
|
||||
|
||||
local expl
|
||||
|
||||
_wanted pods expl 'Perl base pods' compadd -a _perl_basepods
|
Loading…
Reference in New Issue
Block a user