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

Re: hostname completion for ssh / scp



> On 2016-11-05 21:29, Bart Schaefer wrote:
> On Nov 5,  7:54pm, Fourhundred Thecat wrote:
> 
> /etc/hosts is a file read by the DNS resolver library to look up IPs
> for hosts that either aren't found in DNS, or that locally need to
> use a different IP than the one found by a network DNS lookup.  It
> is not there for purposes of configuring completions in the shell,
> and lines that don't have an IP address are useless for the intended
> purpose of the file.
> 
> Read "man 5 hosts".  Bash might let you use it the way you say by way
> of a non-strict parse of the contents, but that doesn't make it right.

I agree. That it works in bash, does not make it right.
It is a useful feature nevertheless.



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