From f94eb407c49d1e721f634bae3c0cca6034c3319b Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Mon, 27 Sep 1999 13:32:35 +0000 Subject: zsh-workers/8062 --- Completion/User/_man | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) (limited to 'Completion/User/_man') diff --git a/Completion/User/_man b/Completion/User/_man index 88d2118c0..ec2af00f0 100644 --- a/Completion/User/_man +++ b/Completion/User/_man @@ -14,12 +14,18 @@ if [[ -n $_comp_correct ]]; then approx="(#a${_comp_correct})" fi -(( $#manpath )) || manpath=$(manpath 2>/dev/null) || +if (( ! $#manpath )); then + local mp=$(manpath 2>/dev/null) + [[ "$mp" == *:* ]] && mp=( ${(s.:.)mp} ) + manpath=( $mp ) +fi + +(( $#manpath )) || manpath=( /usr/man(-/N) /(opt|usr)/(dt|share|X11R6|local)/(cat|)man(-/N) ) # `sman' is the SGML manual directory for Solaris 7. -if [[ $words[2] = (<->*|ln) ]]; then +if [[ $words[2] = (<->*|l|n) ]]; then rep=( $manpath/(sman|man|cat)${words[2]}/${~approx}$PREFIX${~star}$SUFFIX.<->*(N:t) ) else -- cgit 1.4.1