Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: hostname completion for ssh / scp



On Nov 5,  1:29pm, Bart Schaefer wrote:
}
} However, because _combination is used by _ssh_hosts to also call the
} completion for hosts, the users-hosts lookup can succeed even if the
} users-hosts style is unset.  I don't think that was an expected effect.
} However, I don't know the best way to address it.
} 
} I expected to be able to work around this by:
} 
} zstyle -e ':completion:*:(ssh|scp):*:my-accounts' users-hosts 'return 1'

Here's a workaround that actually works:

zstyle -e ':completion:*:(ssh|scp):*:my-accounts' users-hosts \
	'_hosts "$@"; trap false EXIT; return 1' 



Messages sorted by: Reverse Date, Date, Thread, Author