[Bash-completion-commits] [SCM] bash-completion branch, master, updated. ab36c8d29d46a6800f0df88dcf119cd2816c6ecb
David Paleino
d.paleino at gmail.com
Thu Jun 18 11:14:17 UTC 2009
The following commit has been merged in the master branch:
commit ab36c8d29d46a6800f0df88dcf119cd2816c6ecb
Author: David Paleino <d.paleino at gmail.com>
Date: Thu Jun 18 13:12:52 2009 +0200
Added avahi-discovered hosts to _known_hosts_real() (Debian: #518561)
diff --git a/CHANGES b/CHANGES
index 0288644..f7a87d6 100644
--- a/CHANGES
+++ b/CHANGES
@@ -31,6 +31,7 @@ bash-completion (1.x)
* Split dselect completion to contrib/dselect
* Split cardctl completion to contrib/cardctl
* Split pineaddr completion to contrib/pine
+ * Added avahi-discovered hosts to _known_hosts_real() (Debian: #518561)
[ Ville Skyttä ]
* Split yum and yum-arch completion into contrib/yum.
@@ -131,7 +132,7 @@ bash-completion (1.x)
* Patched _known_hosts() to support multiple {Global,User}KnownHosts in SSH
config files, thanks to Thomas Nilsson (Alioth: #311595) (Debian: #524190)
- -- David Paleino <d.paleino at gmail.com> Wed, 20 May 2009 22:08:42 +0200
+ -- David Paleino <d.paleino at gmail.com> Thu, 18 Jun 2009 13:12:36 +0200
bash-completion (1.0)
diff --git a/bash_completion b/bash_completion
index 9bc8e3c..20e3b49 100644
--- a/bash_completion
+++ b/bash_completion
@@ -1192,6 +1192,13 @@ _known_hosts_real()
COMPREPLY=( "${COMPREPLY[@]}" $hosts )
fi
+ # Add hosts reported by avahi, if it's available
+ if type avahi-browse >&/dev/null; then
+ COMPREPLY=( "${COMPREPLY[@]}" $(
+ compgen -W "$( avahi-browse -kcpr _workstation._tcp | \
+ grep ^= | cut -d\; -f7 | sort -u )" -- $cur ) )
+ fi
+
# Now add results of normal hostname completion
COMPREPLY=( "${COMPREPLY[@]}" $( compgen -A hostname -- $cur ) )
--
bash-completion
More information about the Bash-completion-commits
mailing list