From eaa55b546134c5adf461f485d4ab388df2b6ea8b Mon Sep 17 00:00:00 2001 From: Tanaka Akira Date: Mon, 13 Mar 2000 01:55:02 +0000 Subject: zsh-workers/10099 --- Completion/User/_groups | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'Completion/User') diff --git a/Completion/User/_groups b/Completion/User/_groups index b4ecab38c..185b06549 100644 --- a/Completion/User/_groups +++ b/Completion/User/_groups @@ -1,13 +1,14 @@ #compdef newgrp -local expl groups +local expl groups tmp _wanted groups expl group || return 1 if ! zstyle -a ":completion:${curcontext}:" groups groups; then (( $+_cache_groups )) || - if (( ${+commands[ypcat]} )); then - : ${(A)_cache_groups:=${${(s: :)$(_call groups ypcat group.byname)}%%:*}} # If you use YP + if (( ${+commands[ypcat]} )) && + tmp=$(_call groups ypcat group.byname); then + : ${(A)_cache_groups:=${${(f)tmp}%%:*}} # If you use YP else : ${(A)_cache_groups:=${${(s: :)$(