diff --git a/CHANGES b/CHANGES index 846a5ebb..4a847b1d 100644 --- a/CHANGES +++ b/CHANGES @@ -2,9 +2,6 @@ bash-completion (1.x) [ David Paleino ] * Permit .gz files concatenation (Debian: #514377) - * Remove eval() and sed quoting in _known_hosts(), fixes execution (!!!) - of hosts specified by {Global,User}KnownHosts in SSH config files - (Alioth: #311595) * Fix svk completion using $filenames instead of $default (Debian: #524961) * Really add build-dep to aptitude's completion (Debian: #495883) * Fix checks for GNUish userland, thanks to Robert Millan (Debian: #529510) @@ -34,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. @@ -90,6 +88,8 @@ bash-completion (1.x) * Improve rpm group completion (displayed completions are still wrong). * Change many completions to load in memory only if the completed commands are available. + * Invoke the actual mplayer/mencoder command being completed (with full path) + to get various completions instead of simply "mplayer" or "mencoder". [ Todd Zullinger ] * Make yum complete on filenames after install, deplist, update and upgrade @@ -134,7 +134,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 Wed, 20 May 2009 22:08:42 +0200 + -- David Paleino Thu, 18 Jun 2009 13:12:36 +0200 bash-completion (1.0) diff --git a/bash_completion b/bash_completion index 845a099a..0b402477 100644 --- a/bash_completion +++ b/bash_completion @@ -1194,6 +1194,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 ) ) diff --git a/contrib/mplayer b/contrib/mplayer index a6651def..46814695 100644 --- a/contrib/mplayer +++ b/contrib/mplayer @@ -22,12 +22,8 @@ _mplayer() prev=${COMP_WORDS[COMP_CWORD-1]} case "$prev" in - -@(ac|afm|vc|vfm|ao|vo|vop|fstype|demuxer|vf|af)) - _mplayer_options_list mplayer $prev - return 0 - ;; - -@(oac|ovc|of)) - _mplayer_options_list mencoder $prev + -@([av][cfo]|[av]fm|vop|fstype|demuxer|o[av]c|of|profile)) + _mplayer_options_list $cmd $prev return 0 ;; -audiofile) @@ -250,10 +246,6 @@ _mplayer() COMPREPLY=( $( compgen -W 'force= list=' -- $cur ) ) return 0 ;; - -profile) - _mplayer_options_list $cmd $prev - return 0 - ;; esac case "$cur" in