Package: bash-completion Version: 20060301-4ubuntu1 Severity: normal Tags: patch
In a LAN this can be very useful. -- System Information: Debian Release: lenny/sid APT prefers intrepid-updates APT policy: (500, 'intrepid-updates'), (500, 'intrepid-security'), (500, 'intrepid-backports'), (500, 'intrepid'), (101, 'jaunty') Architecture: i386 (i686) Kernel: Linux 2.6.28-8-generic (SMP w/1 CPU core) Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Versions of packages bash-completion depends on: ii bash 3.2-4ubuntu1 The GNU Bourne Again SHell ii ucf 3.0014 Update Configuration File: preserv bash-completion recommends no packages. bash-completion suggests no packages. -- no debconf information
diff --git a/bash_completion b/bash_completion index 8811a70..caed40c 100644 --- a/bash_completion +++ b/bash_completion @@ -2586,6 +2586,17 @@ _known_hosts() COMPREPLY=( "${comprep...@]}" $hosts ) fi + # Add hosts that avahi reports, if avahi is available + if type avahi-browse >&/dev/null; then + COMPREPLY=( "${comprep...@]}" $( + compgen -W "$( + avahi-browse -kcp _workstation._tcp \ + | sed 's/\\0/\\\\0/g' \ + | while IFS=';' read bla bla bla hostn bla bdomain; do + echo ${hostn%%\\*}.$bdomain + done)" -- $ocur)) + fi + # Now add results of normal hostname completion COMPREPLY=( "${comprep...@]}" $( compgen -A hostname -- $ocur ) )