[Bash-completion-devel] bash-completion, known_hosts
Raph
gibboris at gmail.com
Mon Feb 14 21:25:17 UTC 2011
On Mon, Feb 14, 2011 at 09:59:07PM +0100, bandie9100 at gmail.com wrote:
> Hi developers,
>
> i made a simple extension for /etc/bash_completion for
> _known_hosts_real function. Could you include it to package?
>
> # Add ~/.netrc entries
> if [ -r "$HOME/.netrc" ]; then
> COMPREPLY=( "${COMPREPLY[@]}"
> $( compgen -P "$prefix$user" -S "$suffix" -W "$(awk '{for(i=1;i<=NF;i++){if($i=="machine"){j=i+1;print $j}}}' "$HOME/.netrc")" -- "$cur" ) )
> fi
>
> sincerely,
> Bandie
+1
(http://www.mail-archive.com/bash-completion-devel@lists.alioth.debian.org/msg01534.html)
Raph
More information about the Bash-completion-devel
mailing list